Archive for September, 2010
Ping, Windows 7, and the Windows Firewall
If you cannot ping a Windows 7 box, don’t just disable the Windows Firewall. See the following page describing how to enable the included ICMP Echo rule in the Windows Firewall:
http://www.fixya.com/support/r5359816-allow_ping_icmp_echo_request_windows_7
Note that I shut down the Windows Firewall service (net stop mpssvc) and this did not “re-enable” ping. I had to add the firewall rule. There may be another solution, but this solved my problem.
Rob
Consolidating Multiple VMware VMDK Disk Files into One
If you have older VMware Workstation disk images (vmdk files) that are split into multiple parts, you can consolidate them into a single disk image from the command prompt:
vmware-vdiskmanager -r MyVirtualMachineDisk.vmdk -t 0 SingleDiskFile.vmdk
The “-t 0″ means “single growable virtual disk”. If you prefer to preallocate all the storage for the disk, use “-t 2″ instead, which means “preallocated virtual disk.” You can view more options by running the vmware-vdiskmanager command with no parameters. It will show you what options are available.
I found this solution at http://ubuntuforums.org/showthread.php?t=740914. However, don’t let the fact that it’s on an Ubuntu site fool you; it works just fine on Windows.
Enable SQL Server Mgmt Studio to Overwrite Table Designs
By default, SQL Server Management Studio (SSMS) will not let you save changes to the designs of your tables. When you attempt to do so, it wants you to drop and re-create the table. You will typically see a dialog similar to the following:

However, SSMS will actually let you perform such a change without have to drop the table and re-create it. To enable this feature, you need to select Tools / Options from the Menu. Then, navigate to Designers / Table and Database Designers and uncheck the option to “Prevent saving changes that require table re-creation”.

Now click the OK button and try saving your table design changes. Voila!
I owe a big thanks to my friend Jack for teaching me this trick. It has saved me a lot of grief!
VS2010 Automatically Includes Your Text Files as Resources
When you right-click on your WPF project in Visual Studio 2010 (VS2010) and select Add / New Item… / Text File, the “Build Action” on this file is automatically set to “Resource.” So, when you ship your application, this text file will be embedded within it. If this was simply meant to be a readme file for your own benefit, you may not want it embedded in your app. In this case, click on the text file in Solution Explorer (or Solution Navigator), go to the Properties window, and change “Build Action” from “Resource” to “None.”
Change the Default VS2010 Start Page “Language”
When you first run Visual Studio 2010 (VS2010), it asks you to select a profile (e.g. C#, C++). This determines the Start Page displayed when VS2010 starts. Once you pick this, there appears to be no easy way to change your selection (at least none that I’ve found). To see which start pages are available to you, look in the following directory:
32-bit Windows: C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\StartPages\en
64-bit Windows: C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\StartPages\en
Note: you may also need to change your language directory from “en” to your local environment.
You will potentially see a number of files named “Links.<Version>.<VS2010-Language>.xml”. The part we’re interested in is the <VS2010-Language>, e.g. CSharp, FSharp, VC.
To determine which page you current use, browse in Regedit.exe or use the following command:
reg query HKCU\Software\Microsoft\VisualStudio\10.0\StartPage\Default /v Links
You should see a result similar to the following:
Links REG_SZ CSharp
If you wish to change this to a different setting, pick another <VS2010-Language> from the list you saw in your StartPages directory, such as “VC”. You can make this change in Regedit.exe or use the following command:
reg add HKCU\Software\Microsoft\VisualStudio\10.0\StartPage\Default /v Links /t REG_SZ /d VC /f
Now restart VS2010 and you will see your new Start Page.