tag:blogger.com,1999:blog-71423884797430203642024-03-14T11:43:50.038+01:00NJimmyMy thoughts on software development in general and .Net in particularJStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.comBlogger17125tag:blogger.com,1999:blog-7142388479743020364.post-22018753197285873582017-10-07T12:45:00.000+02:002017-10-07T12:45:50.816+02:00Deploy VSTS/TFS build agent with Xcode capability on a MacMake sure you have an updated version of Xcode.<br />
<br />
Begin by opening a Terminal prompt and install the package manager Homebrew.<br />
<br />
<pre class="hljs" style="background: rgb(234, 234, 234); box-sizing: border-box; overflow-x: auto; padding: 15px; text-size-adjust: none;"><code style="box-sizing: border-box; margin-bottom: 0px; margin-top: 0px; padding: 0px;"><span style="color: #444444; font-family: Courier New, Courier, monospace; font-size: x-small;">/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"</span></code></pre>
<br />
Install OpenSSL.<br />
<br />
<pre class="hljs" style="background: rgb(234, 234, 234); box-sizing: border-box; overflow-x: auto; padding: 15px; text-size-adjust: none;"><code style="box-sizing: border-box; margin-bottom: 0px; margin-top: 0px; padding: 0px;"><span style="color: #444444; font-family: Courier New, Courier, monospace; font-size: x-small;">brew update
brew install openssl
mkdir -p /usr/local/lib/
ln -s /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib /usr/local/lib/
ln -s /usr/local/opt/openssl/lib/libssl.1.0.0.dylib /usr/local/lib/</span></code></pre>
<br />
Install git.<br />
<br />
<pre class="hljs" style="background: rgb(234, 234, 234); box-sizing: border-box; overflow-x: auto; padding: 15px; text-size-adjust: none;"><code style="box-sizing: border-box; font-family: Consolas, "Courier New", monospace; margin-bottom: 0px; margin-top: 0px; padding: 0px;"><span style="color: #444444; font-size: x-small;">brew install git</span></code></pre>
<br />
Restart Terminal and cd into the dir where you will create your agent dir.<br />
<br />
Download <a href="https://github.com/Microsoft/vsts-agent/releases/download/v2.123.0/vsts-agent-osx.10.11-x64-2.123.0.tar.gz">https://github.com/Microsoft/vsts-agent/releases/download/v2.123.0/vsts-agent-osx.10.11-x64-2.123.0.tar.gz</a>.<br />
<pre class="hljs" style="background: rgb(234, 234, 234); box-sizing: border-box; overflow-x: auto; padding: 15px; text-size-adjust: none;"><code style="box-sizing: border-box; margin-bottom: 0px; margin-top: 0px; padding: 0px;"><span style="color: #444444; font-family: Courier New, Courier, monospace; font-size: x-small;">mkdir myagent && cd myagent
tar zxvf ~/Downloads/vsts-agent-osx.10.11-x64-2.123.0.tar.gz</span></code></pre>
<br />
Download the patched version of System.Net.Http from <a href="https://ci.dot.net/job/dotnet_corefx/job/release_1.1.0/job/osx_release/lastSuccessfulBuild/artifact/bin/build.tar.gz">https://ci.dot.net/job/dotnet_corefx/job/release_1.1.0/job/osx_release/lastSuccessfulBuild/artifact/bin/build.tar.gz</a>. Without this you won't be able to connect to VSTS/TFS.<br />
<pre class="hljs" style="background: rgb(234, 234, 234); box-sizing: border-box; overflow-x: auto; padding: 15px; text-size-adjust: none;"><code style="box-sizing: border-box; font-family: Consolas, "Courier New", monospace; margin-bottom: 0px; margin-top: 0px; padding: 0px;"><span style="color: #444444; font-size: x-small;">tar -xzvf build.tar bin/Unix.AnyCPU.Release/System.Net.Http/System.Net.Http.dll</span></code></pre>
<br />
Make a backup of myagent/bin/System.Net.Http.dll before replacing it with the patched version.<br />
<br />
Create a Personal Access Token by following <a href="https://docs.microsoft.com/sv-se/vsts/build-release/actions/agents/v2-osx#permissions">https://docs.microsoft.com/sv-se/vsts/build-release/actions/agents/v2-osx#permissions</a>.<br />
Create a folder named LaunchAgents in /Users/[logged in user]/Library.<br />
<br />
Configure the agent.<br />
<br />
<pre class="hljs" style="background: rgb(234, 234, 234); box-sizing: border-box; overflow-x: auto; padding: 15px; text-size-adjust: none;"><span style="color: #444444; font-family: Courier New, Courier, monospace; font-size: x-small;"><code style="box-sizing: border-box; margin-bottom: 0px; margin-top: 0px; padding: 0px;"><span style="font-family: Courier New, Courier, monospace;">./config.sh
Accept terms: Y
Server URL: https://[your account].visualstudio.com
<enter> (PAT)
PAT: [your PAT]</span>
</code><enter> (default agent pool)
pool name: []
<enter> (_work working folder)</span></pre>
<br />
Install and run the agent as a launchd service.<br />
<br />
<pre class="hljs" style="background: rgb(234, 234, 234); box-sizing: border-box; overflow-x: auto; padding: 15px; text-size-adjust: none;"><code style="box-sizing: border-box; font-family: Consolas, "Courier New", monospace; margin-bottom: 0px; margin-top: 0px; padding: 0px;"><span style="color: #444444; font-size: x-small;">./svc.sh install
./svc.sh start</span></code></pre>
<br />
Source: <a href="https://docs.microsoft.com/sv-se/vsts/build-release/actions/agents/v2-osx#run-as-a-launchd-service">https://docs.microsoft.com/sv-se/vsts/build-release/actions/agents/v2-osx#run-as-a-launchd-service</a>.<br />JStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.com0tag:blogger.com,1999:blog-7142388479743020364.post-29558300714590751522016-03-02T21:22:00.002+01:002016-03-05T21:03:07.071+01:00How to include generated files in Visual Studio Web Deployment Package without adding them to Source ControlWhen using Web Deployment the default is to only have it include the files that are needed to run the application. You can tell Visual Studio to include all files in the project or project folder but that could be messy.<br />
<br />
Let's say we want to generate CSS from SCSS. In that case we wouldn't want to include the generated file into Source Control but rather generate it whenever we build or change some SCSS.<br />
<br />
Now comes the tricky part. In order to include the generated file in the project so that Web Deployment would include it but not add it to Source Control we can use a .tfignore file. I've created one and put it in the solution root. To have it ignore the generated CSS file in my web project we simply have to add this line: <br />
\Corp.Web\Static\SCSS\site.css<br />
<div>
<br />
One confusing bit is when you add the generated file to your project it still shows up in Pending Changes. Just Undo that change and it won't show up as a pending change anymore.<br />
<br />
One last thing piece to the puzzle is to hide the generated file from Solution Explorer since we don't ever want to edit that file manually.<br />
<br />
Edit the project file, find the generated file, add the Visible tag inside the Content tag and set it to false:<br />
<Content Include="Static\SCSS\site.css"><br />
<Visible>false</Visible><br />
</Content></div>
JStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.com7tag:blogger.com,1999:blog-7142388479743020364.post-9615616186813064832015-12-18T11:33:00.001+01:002015-12-18T11:33:22.530+01:00Using Zurb Foundation Sites with Sass in Visual Studio 2015I'm currently involved in a project where we decided to use <a href="http://foundation.zurb.com/">Zurb Foundation</a> and since it's built with <a href="http://sass-lang.com/">Sass</a> we should be able to customise it to our needs.<br />
<br />
Unfortunately we're stuck with Visual Studio 2015 and Asp.Net 4 + MVC 5 so we don't have the luxury of having <a href="https://www.npmjs.com/">NPM</a> or <a href="http://bower.io/">Bower</a> built in as in Asp.Net 5 + MVC 6. Yes, there are NuGet packages for Foundation but they're ancient.<br />
<br />
This part of the process is not optimal but I downloaded the latest version of Foundation separately using the following NPM command:<br />
<br />
<span style="font-family: "courier new" , "courier" , monospace;">npm install foundation-sites</span><br />
<br />
I then took all the contents and added to my project.<br />
<br />
<table cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: left; margin-right: 1em; text-align: left;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgnz1C3OuYmofoY5qmenDjx7mVbJ5sns2_V2HOR0MoDyHf1cSCrzRzOGiuRKBoS-kJhQK3OIcsSxIIaC7a4vPFcVSz3zD52p04c7TpzfdPpLKGLMiG6X_OkBX0i3cXy_8PUoDXEeDHyvAM/s1600/Folder.png" imageanchor="1" style="clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgnz1C3OuYmofoY5qmenDjx7mVbJ5sns2_V2HOR0MoDyHf1cSCrzRzOGiuRKBoS-kJhQK3OIcsSxIIaC7a4vPFcVSz3zD52p04c7TpzfdPpLKGLMiG6X_OkBX0i3cXy_8PUoDXEeDHyvAM/s1600/Folder.png" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Folder structure</td></tr>
</tbody></table>
<span id="goog_1833834009"></span><span id="goog_1833834010"></span><br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
To be able to compile Sass into Css right within Visual Studio we need to install the extension <a href="https://visualstudiogallery.msdn.microsoft.com/3b329021-cd7a-4a01-86fc-714c2d05bb6c">Web Compiler</a>.<br />
<br />
The next step was to create our main Sass file which I named site.scss. I put in a folder called SCSS. To have Web Compiler compile this, just right-click and choose Web Compiler -> Compile File.<br />
<br />
<table cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: left; margin-right: 1em; text-align: left;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgptN9lzBtfq2XKgidW6X5Xcxb9HB5dA3RAgkwgjYs9mZfjTe_ZvYfJ0GlKwD-fkSPcOPChqy70Isok9OQ8zVOcOam8lDKhGlZwaRoQo-cQmp4Pih9KiVA_lF936FOmkT4X_ze-lbt828w/s1600/Compile.png" imageanchor="1" style="clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgptN9lzBtfq2XKgidW6X5Xcxb9HB5dA3RAgkwgjYs9mZfjTe_ZvYfJ0GlKwD-fkSPcOPChqy70Isok9OQ8zVOcOam8lDKhGlZwaRoQo-cQmp4Pih9KiVA_lF936FOmkT4X_ze-lbt828w/s1600/Compile.png" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Compile file</td></tr>
</tbody></table>
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
In site.scss we can then just import Foundation Sites to include it in our compiled Css.<br />
<br />
<table cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: left; margin-right: 1em; text-align: left;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiDTxZVCpqh5akFZdttTo-gFx9bnd5kHeBzNGL527hHEocshTf-fNd0y9Bn0R41mc3RQ_DAKnkjUGrrGCO-bznNSM-PzE_X3ZBiqq3Rc-dWkep_0sM4XMjb2oAhtMbNCFi10aE7SLVkx00/s1600/include+foundation.png" imageanchor="1" style="clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiDTxZVCpqh5akFZdttTo-gFx9bnd5kHeBzNGL527hHEocshTf-fNd0y9Bn0R41mc3RQ_DAKnkjUGrrGCO-bznNSM-PzE_X3ZBiqq3Rc-dWkep_0sM4XMjb2oAhtMbNCFi10aE7SLVkx00/s1600/include+foundation.png" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Include Foundation</td></tr>
</tbody></table>
<br />
<br />
<br />
<br />
<br />
Here comes one tricky part and that is to tell Web Compiler about the whereabouts of Foundation. This can be done in the configuration file compilerconfig.json.defaults that gets created in the root of your project when you choose to compile a file with Web Compiler.<br />
Find the node under "sass" that's called "includePath" and give it a value of "./Static/Framework/Foundation-sites/scss".<br />
<br />
Now you should be good to go and whenever site.scss gets saved a site.css including Foundation should be compiled.<br />
<br />
For easier debugging using browser developer tools you could get <a href="http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/">Source Maps</a> working by enabling Source Maps in compileconfig.json that is located within the root of your project.<br />
<br />
<table cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: left; margin-right: 1em; text-align: left;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh7cr1PXgcxurp3hDfPJCudxLLTOFOJgjuR_Z_hXiLz20F46LFV0m-Fd2uGe8MSOTpt-zPho4gsUJT8uc_pyGYFL3HUM01uvX1RaI40QdKmAYC6vrqh_xW7bGsVDjSqnmCSe9zf9jS1iH4/s1600/source+map.png" imageanchor="1" style="clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh7cr1PXgcxurp3hDfPJCudxLLTOFOJgjuR_Z_hXiLz20F46LFV0m-Fd2uGe8MSOTpt-zPho4gsUJT8uc_pyGYFL3HUM01uvX1RaI40QdKmAYC6vrqh_xW7bGsVDjSqnmCSe9zf9jS1iH4/s1600/source+map.png" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Source map setting</td></tr>
</tbody></table>
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
Please note! While the last step enables Source maps in the compiled Css, the path to them is incorrect. This could be solved in the configuration file compileconfig.json.defaults.<br />
Find the node under "sass" that's called "soruceMapRoot" (yes it's misspelled) and change it to "/".JStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.com2tag:blogger.com,1999:blog-7142388479743020364.post-19843354769418471202015-12-18T10:15:00.003+01:002015-12-18T10:16:39.568+01:00Adding alternative NuGet package source in Visual Studio solutionWhile it's possible to add a new package source to Visual Studio this is not optimal if there are more than one developer or if a build server is used.<br />
<br />
An alternative is to add a .nuget folder and within that folder add a NuGet.config file with the following content:<br />
<br />
<span style="font-family: "courier new" , "courier" , monospace;"><?xml version="1.0" encoding="utf-8"?><br /><configuration><br /> <packageSources><br /> <add key="NuGet official package source" value="https://nuget.org/api/v2/" /><br /> <add key="Some other package source" value="some url to the other package source" /><br /> </packageSources><br /> <disabledPackageSources /><br /> <activePackageSource><br /> <!-- this tells that all of them are active --><br /> <add key="All" value="(Aggregate source)" /><br /> </activePackageSource><br /></configuration></span><br />
<br />
<span style="font-family: "courier new" , "courier" , monospace;"><span style="font-family: Times;">Source</span></span><br />
<span style="font-family: Courier New, Courier, monospace;"><a href="https://docs.nuget.org/consume/nuget-config-file">https://docs.nuget.org/consume/nuget-config-file</a></span>JStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.com3tag:blogger.com,1999:blog-7142388479743020364.post-85948828500758095332015-12-18T08:40:00.001+01:002015-12-18T08:40:34.349+01:00Prevent packages folder from being added to Team Foundation Version Control in Visual Studio 2015Solutions built with Visual Studio 2015 uses NuGet Automatic Package Restore instead of MSBuild-integrated package restore. At least for me this made Visual Studio want to check in the package folder into Team Foundation Version Control.<br />
<br />
To prevent the packages folder from being added to Team Foundation Version Control in Visual Studio 2015 you can add a .nuget folder in your solution folder. In the .nuget folder add a file named NuGet.config with the following content:<br />
<br />
<div class="p1">
<span style="font-family: Courier New, Courier, monospace;"><?<span class="s1">xml</span> <span class="s2">version</span>=<span class="s3">"</span>1.0<span class="s3">"</span> <span class="s2">encoding</span>=<span class="s3">"</span>utf-8<span class="s3">"</span>?></span></div>
<div class="p2">
<span style="font-family: Courier New, Courier, monospace;"><span class="s4"><</span>configuration<span class="s4">></span></span></div>
<div class="p2">
<span style="font-family: Courier New, Courier, monospace;"><span class="s4"> <</span>solution<span class="s4">></span></span></div>
<div class="p1">
<span style="font-family: Courier New, Courier, monospace;"> <<span class="s1">add</span> <span class="s2">key</span>=<span class="s3">"</span>disableSourceControlIntegration<span class="s3">"</span> <span class="s2">value</span>=<span class="s3">"</span>true<span class="s3">"</span> /></span></div>
<div class="p2">
<span style="font-family: Courier New, Courier, monospace;"><span class="s4"> </</span>solution<span class="s4">></span></span></div>
<div class="p2">
<span style="font-family: Courier New, Courier, monospace;"><span class="s4"></</span>configuration<span class="s4">></span></span></div>
<div class="p2">
<span class="s4"><br /></span></div>
<div class="p2">
<span class="s4">This tells Nuget to not even call Visual Studio about the changes to the packages folder.</span></div>
<div class="p2">
<span class="s4"><br /></span></div>
<div class="p2">
<span class="s4">For TFS 2012 and later also add a .tfignore file in your solution folder with the following content:</span></div>
<div class="p2">
<span class="s4"><br /></span></div>
<div class="p1">
<span style="font-family: Courier New, Courier, monospace;">## Ignore the NuGet packages folder in the root of the repository</span></div>
<div class="p1">
<span style="font-family: Courier New, Courier, monospace;">packages</span></div>
<div class="p2">
<span style="font-family: Courier New, Courier, monospace;"><br /></span></div>
<div class="p1">
<span style="font-family: Courier New, Courier, monospace;">#include package target files which may be required for msbuild</span></div>
<div class="p2">
<span class="s4"><span style="font-family: Courier New, Courier, monospace;">
</span></span></div>
<div class="p1">
<span style="font-family: Courier New, Courier, monospace;">!packages/*.targets</span></div>
<div class="p1">
<br /></div>
<div class="p1">
This will ignore changes to the packages folder.</div>
<div class="p2">
<span class="s4"><br /></span></div>
<div class="p2">
<span class="s4">Sources</span></div>
<div class="p2">
<span class="s4"><a href="https://docs.nuget.org/consume/package-restore">https://docs.nuget.org/consume/package-restore</a></span></div>
<div class="p2">
<a href="http://docs.nuget.org/consume/package-restore/migrating-to-automatic-package-restore">http://docs.nuget.org/consume/package-restore/migrating-to-automatic-package-restore</a></div>
JStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.com0tag:blogger.com,1999:blog-7142388479743020364.post-44052104486102985322012-12-14T20:55:00.001+01:002012-12-14T21:00:54.399+01:00How to enable remote/external requests/connections on IIS Express<p>First you need to open your firewall to let through TCP connections on the local port(s) that you run IIS Express on, typically 8080.</p> <p>Secondly you have to configure HTTP.SYS to allow your application, running as a standard user, to listen to external traffic over the wire. You can do this on Windows 7 or Windows 8 by running the following command from an administrative prompt:<br><font face="Courier New">netsh http add urlacl url=http://[your-machine- name]:8080/ user=everyone</font></p> <p>And last but not least you might be missing a binding information in applicationhost.config. You can find it in your user profile (%userprofile%\Documents\IISExpress\config\applicationhost.config). Locate your site under the <Sites> node. Since there are potentially a whole bunch of sites there you can find it by searching for the physical path in which all files for your site belongs. Now add a binding with your machine name:<br><font face="Courier New"><binding protocol="http" bindingInformation=":8080:[your-machine-name]" /></font><br>Finally, don’t forget to restart IIS Express for this change to carry into effect.</p> JStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.com1tag:blogger.com,1999:blog-7142388479743020364.post-39371817556152612482011-05-17T16:50:00.001+02:002011-05-17T16:50:53.462+02:00How to test mail delivery during development without a real SMTP server<p>Ever wanted an easy way to test how mails look like when sent from your application without using a real SMTP server? </p> <p>Using a real server might possible include setting up security, you never know if your mails are stuck in spam filters and you are always scared that you sent it to real people by accident. Windows 7 for example does not include a SMTP service.</p> <p>The answer is <a href="http://smtp4dev.codeplex.com/" target="_blank">smtp4dev</a>. This is a lightweight service that sits in the system tray and catches all mail sent to localhost without delivering them. The received messages can quickly be viewed and inspected.</p> JStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.com8tag:blogger.com,1999:blog-7142388479743020364.post-53653559627458264052011-03-13T18:16:00.004+01:002011-03-13T18:33:36.561+01:00How to evolve as a developerI'm pretty competitive and I recently found out that a college of mine is very active on <a href="http://stackoverflow.com/">Stack Overflow</a> so I decided to start "chasing" him. It took about a month to gain 800 points which got me over 1.000 and made me the among the top 300 contributers for some of those weeks. I wasn't really reaching for any particular score but I had to have some reachable goal and 1.000 seemed like a nice figure.<div><br /></div><div>During this adventure it hit me what a perfect way of gaining knowledge this is. To give a good answer takes thinking, researching and not to forget, good communication skills. I learned a lot from this and got a lot of great feedback from fellow developers.</div><div><br /></div><div>So my advise is that you should pick a topic (tag on Stack Overflow) that you want to learn more about and start asking, reading and answering questions.</div><div><br /></div><div>My next tag will be <a href="http://stackoverflow.com/questions/tagged/jquery-mobile">jQuery Mobile</a>.</div><div><br /></div><div>See you on <a href="http://stackoverflow.com/">Stack Overflow</a>!</div>JStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.com0tag:blogger.com,1999:blog-7142388479743020364.post-86243974507314183232011-03-10T15:36:00.001+01:002011-03-10T15:36:02.008+01:00How to make diff/merge in Visual Studio about 10 times better<ol> <li>Buy <a href="http://www.scootersoftware.com/shop.php" target="_blank">Beyond Compare</a></li> <li><a href="http://whyiamright.wordpress.com/2008/01/18/changing-the-diffmerge-program-used-by-visual-studio/" target="_blank">Make Visual Studio use Beyond Compare for diff and merge</a>.</li></ol> <p>If you’re on a tight budget this could also <a href="http://blog.paulbouwer.com/2010/01/31/replace-diffmerge-tool-in-visual-studio-team-system-with-winmerge/" target="_blank">be done</a> with <a href="http://winmerge.org/" target="_blank">WinMerge</a>.</p> JStormhttp://www.blogger.com/profile/14323392603026449888noreply@blogger.com0tag:blogger.com,1999:blog-7142388479743020364.post-47236855643770999492011-02-10T20:55:00.002+01:002011-02-11T11:59:54.668+01:00jsFiddle – Not just an editorI got a sudden urge to gain some reputation on <a href="http://stackoverflow.com/" target="_blank">Stack Overflow</a> and went looking for questions with a bounty when I found this particularly interesting one - <a href="http://stackoverflow.com/questions/4925550/loosing-hover-when-animating-with-jquery-without-moving-mouse" target="_blank">Loosing hover when animating with jQuery (without moving mouse)</a>.<br />
The author of the question had made a <a href="http://jsfiddle.net/nZGYA/" target="_blank">fiddle</a> so there was no effort in trying to reproduce the problem which is often a time consuming business.<br />
I made my own <a href="http://jsfiddle.net/jimmysv/3tzAt/15/" target="_blank">fork</a> and started hacking away. After a while I came up with a solution and saved my fork. The solution might not be the prettiest you seen but what’s pretty is how <a href="http://jsfiddle.net/" target="_blank">jsFiddle</a> worked as a playground that everyone can use with only a browser. Combined with <a href="http://stackoverflow.com/" target="_blank">Stack Overflow</a> this is pretty powerful stuff for getting help from the community.<br />
In the time of writing I haven’t got any feedback on my <a href="http://stackoverflow.com/questions/4925550/loosing-hover-when-animating-with-jquery-without-moving-mouse/4961660#4961660" target="_blank">answer</a> but I’m happy nevertheless for finding such a useful tool.Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-7142388479743020364.post-68675852773074868132011-02-10T14:13:00.001+01:002011-02-10T14:33:47.230+01:00How to find nested controls in ASP.Net Webforms<p>I made a little helper class to find all controls of a certain type on a page or within any control that can contain other controls.</p> <p>Please use it with care since it could be quite heavy on a page with thousands of control. Do not pass the entire page unless absolutely necessary. <style type="text/css">.csharpcode, .csharpcode pre<br />{<br /> font-size: small;<br /> color: black;<br /> font-family: consolas, "Courier New", courier, monospace;<br /> background-color: #ffffff;<br /> /*white-space: pre;*/<br />}<br />.csharpcode pre { margin: 0em; }<br />.csharpcode .rem { color: #008000; }<br />.csharpcode .kwrd { color: #0000ff; }<br />.csharpcode .str { color: #006080; }<br />.csharpcode .op { color: #0000c0; }<br />.csharpcode .preproc { color: #cc6633; }<br />.csharpcode .asp { background-color: #ffff00; }<br />.csharpcode .html { color: #800000; }<br />.csharpcode .attr { color: #ff0000; }<br />.csharpcode .alt <br />{<br /> background-color: #f4f4f4;<br /> width: 100%;<br /> margin: 0em;<br />}<br />.csharpcode .lnum { color: #606060; }<br /></style> </p> <div id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet"><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #008000"><font size="1">/// <summary></font></span></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #008000"><font size="1">/// Finds all controls of type T stores them in FoundControls</font></span></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #008000"><font size="1">/// </summary></font></span></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #008000"><font size="1">/// <typeparam name="T"></typeparam></font></span></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"><span style="color: #0000ff">private</span> <span style="color: #0000ff">class</span> ControlFinder<T> <span style="color: #0000ff">where</span> T : Control </font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1">{</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> <span style="color: #0000ff">private</span> <span style="color: #0000ff">readonly</span> List<T> _foundControls = <span style="color: #0000ff">new</span> List<T>();</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> <span style="color: #0000ff">public</span> IEnumerable<T> FoundControls</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> {</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> get { <span style="color: #0000ff">return</span> _foundControls; }</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> } </font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> </font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> <span style="color: #0000ff">public</span> <span style="color: #0000ff">void</span> FindChildControlsRecursive(Control control)</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> {</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> <span style="color: #0000ff">foreach</span> (Control childControl <span style="color: #0000ff">in</span> control.Controls)</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> {</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> <span style="color: #0000ff">if</span> (childControl.GetType() == <span style="color: #0000ff">typeof</span>(T))</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> {</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> _foundControls.Add((T)childControl);</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> }</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> <span style="color: #0000ff">else</span></font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> {</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> FindChildControlsRecursive(childControl);</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> }</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> }</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1"> }</font></pre><!--CRLF--><pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><font size="1">}</font></pre><!--CRLF--></div></div> Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-7142388479743020364.post-51153984044386193162011-02-09T09:42:00.002+01:002011-02-09T10:58:40.443+01:00How to expand/increase the size of an existing virtual hard disk in VMware PlayerI guess I was a bit stingy when I initially set the size of my virtual hard disk and had to pay for that later on. But sometimes it’s impossible to foresee a future need.<br />
Don’t you worry now! It’s a piece of cake to expand the virtual hard disk at a later point in time. Just follow these steps:<br />
<ol><li>Make sure to backup your virtual machine before proceeding. Just incase!<br />
</li>
<li>From VWware Player (I’m using version 3.1.3), select the virtual machine you want to expand and click <em>Edit virtual machine settings</em>.<br />
</li>
<li>Choose the device <em>Hard Disk (IDE), </em>click the <em>Utilities</em> button and choose <em>Expand…</em>.<br />
</li>
<li>Enter the new maximum size in GB and click <em>Expand</em>. This will take a moment.<br />
<br />
<a href="http://lh3.ggpht.com/_RzJrOiWRPHA/TVJTdIQE8WI/AAAAAAAAEU4/Vt6-IAoCUbM/s1600-h/image%5B3%5D.png"><img alt="image" border="0" height="310" src="http://lh6.ggpht.com/_RzJrOiWRPHA/TVJTdi2xvZI/AAAAAAAAEU8/Csu1mNZ9E3U/image_thumb%5B1%5D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="382" /></a><br />
<br />
Your virtual hard disk is now expanded but the guest operating system is still not aware of this.<br />
</li>
<li>Start your virtual machine.<br />
</li>
<li>If your guest operating system is Windows Server 2008, Windows Vista or Windows 7 you could expand the volume in Disk Manager. But if your guest operating system is Windows XP like mine was you have to use a third party utility. I used EASEUS Partition Master which has a free edition for home users.<br />
</li>
<li>Download, install and start <a href="http://www.partition-tool.com/personal.htm" target="_blank">EASEUS Partition Master – Home Edition</a>.<br />
</li>
<li>Choose the partition you want to expand and click <em>Resize/Move Partition</em>. Move the slider to the desired size (probably all the way to the right) and click <em>OK</em>.<br />
<br />
<a href="http://lh6.ggpht.com/_RzJrOiWRPHA/TVJTeH1zjAI/AAAAAAAAEVA/d9M_mfigmrM/s1600-h/image%5B11%5D.png"><img alt="image" border="0" height="357" src="http://lh5.ggpht.com/_RzJrOiWRPHA/TVJTegaEG0I/AAAAAAAAEVE/wIvwMdLVSvA/image_thumb%5B4%5D.png?imgmax=800" style="background-image: none; border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline; padding-left: 0px; padding-right: 0px; padding-top: 0px;" title="image" width="396" /></a><br />
</li>
<li>Click <em>Apply</em> and EASEUS applies the new size to the volume.<br />
</li>
<li>You can now stop using <a href="http://www.piriform.com/ccleaner" target="_blank">CCleaner</a> every five minutes <img alt="Smile" class="wlEmoticon wlEmoticon-smile" src="http://lh4.ggpht.com/_RzJrOiWRPHA/TVJTfEZVJiI/AAAAAAAAEVI/LMHVk8DNJLM/wlEmoticon-smile%5B2%5D.png?imgmax=800" style="border-bottom-style: none; border-left-style: none; border-right-style: none; border-top-style: none;" /></li>
</ol>Unknownnoreply@blogger.com2tag:blogger.com,1999:blog-7142388479743020364.post-27087835803249895912011-02-02T09:53:00.003+01:002016-11-26T17:30:34.835+01:00Forcing UI redraw/repaint in IE7A while ago I had a nasty problem with an element that got on top of other elements and was not clickable anymore. This happened in Internet Explorer 7 when I changed the position from absolute to static during horizontal scrolling.<br />
I tried several techniques for redrawing the element but none of them were successful until I stumbled upon this method:<br />
<div class="csharpcode">
<pre class="alt"><span class="kwrd">var</span> nastyElement = $(<span class="str">"#elementId"</span>);</pre>
<pre class="alt">nastyElement.css(<span class="str">"display"</span>, <span class="str">"none"</span>);</pre>
<pre class="alt">nastyElement[0].offsetHeight; // redraw</pre>
<pre class="alt">nastyElement.css(<span class="str">"display"</span>, <span class="str">"block"</span>);</pre>
</div>
Credits go to vasko who wrote about this on <a href="http://ajaxian.com/archives/forcing-a-ui-redraw-from-javascript">http://ajaxian.com/archives/forcing-a-ui-redraw-from-javascript</a>.Unknownnoreply@blogger.com2tag:blogger.com,1999:blog-7142388479743020364.post-63873902285433250912008-01-18T13:04:00.001+01:002009-04-19T18:02:49.517+02:00Passed another Microsoft exam<p>This time it was the dreaded <a href="http://www.microsoft.com/learning/exams/70-529.mspx" target="_blank">70-529</a>, dreaded because I seldom use the techniques included (Web Services with and without WSE, .Net Remoting, Serviced Components, MSMQ). Well, of course I've used Web Services but never had the need to apply WSE (Web Service Enhancements) which makes things a lot more complicated and, by the way, is nowadays outdated by <a href="http://wcf.netfx3.com/" target="_blank">WCF</a>. Nevertheless I've learned a lot and if I had knew what I know now, I would probably have solved some challenges in the past differently.</p><p>Another sign of me finding this exam pretty tough, other than using adjectives such as dreaded, would be the time spent on studying. Roughly about 3 months. Obviously not at full rate, but I mean... 3 months!!! This is probably the first time I've completed all the lesson reviews, labs and included practice tests (in <a href="http://www.amazon.com/MCTS-Self-Paced-Training-70-529-Pro-Certification/dp/0735623325/ref=pd_bbs_sr_1?ie=UTF8&s=books&qid=1200668469&sr=8-1" target="_blank">this</a> book). But, hey! It paid of. If you are thinking I over-studied, you're absolutely right! I scored 905 out of 1000. 700 is needed to pass. Well, ok for <a href="http://www.microsoft.com/learning/exams/70-300.mspx" target="_blank">70-300</a> I read 2 books and a whole lot of online articles but was never close to 905.</p><p> </p><p>OMG! What about the level of detail on those exams. It's crazy! You actually have to know stuff like the entire schema of every imaginable XML based configuration file and just about every namespace, interface, class, method and associated signature in the entire framework and then some. One has to stretch ones imagination quite a bit to find the reason.</p><blockquote><p>Picture this: You're stranded on a deserted island with nothing but your laptop. Somehow the laptop took a beating and all the sectors where Visual Studio was installed got demolished (MSDN included). That could happen! </p><p>Now for the not so likely part. In all you're desperation, being on a deserted island and all, you find the sudden urge to put together a nice .Net app. Your toolbox: notepad and one VB.Net (what else) standalone compiler. No problem 'cause you're certified! You know everything there is to know by heart.</p></blockquote><p>Come on, seriously! Hook me up with MSDN, Intellisense and <a href="http://www.aisto.com/roeder/dotnet/" target="_blank">Reflector</a> and give me your best shot.</p><p>I think the big advantage you got, as a certified developer, is knowledge about what's available, in your toolbox if you will.</p><p> </p><p>Anyway, now it's time for my little ritual that I've been looking forward to for some time now. It's nothing much but it always feels nice. It includes:</p><ul><li>Bringing all books to the office and putting them in our overly crowded bookshelf and adding them to a list (Sharepoint of course)</li><li>Deleting any practice tests from the laptop</li><li>Finally, showing the certificate to the boss to collect some bonus</li></ul><p> </p><p>My long term goal is to become <a href="http://www.microsoft.com/learning/mcp/mcpd/entapp/default.mspx" target="_blank">MCPD Enterprise Application Developer</a> but if any exams for WCF, WF or WPF becomes available I will take them first. Not in beta though. I did that mistake once and was actually one question away from succeeding with <a href="http://www.microsoft.com/learning/exams/70-510.mspx" target="_blank">70-510 Visual Studio 2005 Team Foundation Server</a>. Imagine a customer seeing that and hiring me to set up their TFS for their worldwide organization of developers, CCM, project managers, testers and so on. Wait a minute! Haven't I found myself in that situation before? Nah, not likely for a consultant ;) </p>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-7142388479743020364.post-74901292600875657092008-01-14T11:16:00.000+01:002008-01-18T22:31:53.855+01:00Do you need a progress bar to go with your site?<p>Are you in a quick need of a progress bar and tired of being bullied by proud designers? Some of them will actually order you to stand behind a line, singing <a href="http://www.youtube.com/watch?v=VUoEil40qZA" target="_blank">I Will Always Love You</a> like Whitney Houston while doing the <a href="http://www.youtube.com/watch?v=9z7t-Ox3XvU" target="_blank">Macarena</a> just to think about helping you. Tell them gently to stick their attitude where the sun don't shine and then follow these simple steps:</p> <ol> <li>Aim your browser to <a title="http://www.ajaxload.info/" href="http://www.ajaxload.info/">http://www.ajaxload.info/</a></li> <li>Choose one of many templates (indicator type)</li> <li>Choose background color (or transparent) depending on your site</li> <li>Choose foreground color to go with your site. If you want a new color, why not try one of many color scheme tools. Here's one <a title="http://www.steeldolphin.com/color_scheme.html" href="http://www.steeldolphin.com/color_scheme.html">http://www.steeldolphin.com/color_scheme.html</a> for you</li> <li>Click Generate it ! - Voilà</li> </ol> Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-7142388479743020364.post-32524280371138215952007-07-30T16:30:00.000+02:002008-01-19T12:56:51.679+01:00Developing CSS and Javascript<p>When developing CSS and Javascript all help available is much appreciated. One way to go is to use hook up your browser with plug-ins.</p> <p>My previous plug-in of choice was <a href="http://chrispederick.com/work/web-developer/" target="_blank">Web Developer</a> for Firefox but I was never really satisfied. My new favorite is definitely <a href="http://www.getfirebug.com/" target="_blank">Firebug</a>. I can't even put any words to tell you how impressed I am by this tool. Add it's buddy <a href="https://addons.mozilla.org/en-US/firefox/addon/249" target="_blank">HTML Validator</a> and you got a strong duo that will make you, Google and your customers happy :)</p> <p>Without doubt you, as a web developer, are brutally aware of the fact that Firefox and Internet Explorer renders things differently. Luckily Microsoft recently released <a href="http://www.microsoft.com/downloads/details.aspx?familyid=e59c3964-672d-4511-bb3e-2d5e1db91038&displaylang=en" target="_blank">Internet Explorer Developer Toolbar</a>. It's not as good as Firebug but it still helps a lot. I don't really see this as a problem because you should always build your web applications for Firefox and then customize them for Internet Explorer using conditional comments (<!--[if IE]> and so on). When testing for Internet Explorer 6, and that is absolutely needed since more than 50% still uses it according to <a href="http://www.thecounter.com/stats/2007/June/browser.php" target="_blank">TheCounter</a>, I simply use a lightweight <a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=21EABB90-958F-4B64-B5F1-73D0A413C8EF&displaylang=en" target="_blank">Virtual PC image</a> supplied by Microsoft.</p> Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-7142388479743020364.post-39482530864672324102007-06-04T10:00:00.000+02:002008-01-19T13:33:31.629+01:00Problem opening documents from Sharepoint<p></p><p><span style="font-size:130%;"><strong>Symptom</strong></span></p><p>When trying to open a document from Sharepoint the browser freezes.</p><p><span style="font-size:130%;"><strong>Possible cause</strong></span></p><p>Upgrading from Office 2003 to 2007.</p><p><span style="font-size:130%;"><strong>Solution</strong></span></p><ol><li>In Windows Explorer, navigate to C:\Program Files\Microsoft Office\Office12</li><li>Delete owssup.dll</li><li>Run the Office diagnostics by selecting Start > All Programs > Microsoft Office Diagnostics. This tool will find the missing component and install the "correct" version.</li></ol><p>I actually couldn't follow step 3 since I didn't have Office diagnostics installed. I used Repair from the installation wizard instead and that worked like a charm.</p>Unknownnoreply@blogger.com1