IE9 Go to an intranet site for a single word entry in the address bar

Unlike IE8, in IE9, if you type an intranet site name in the address bar without http, IE9 will redirect you to the bing search page with the site name as keyword. IE9 also recognize you might want to go to an intranet so there is prompt pop up ask if you want to go to internal site.

5181943752_6bd422793e

This means one more click for many users. You can enforce IE 9 to go to intranet site directly for single word entry by following these steps.

Continue reading

IDE/ATAPI Account does not have sufficient privilege to open attachment

You might get following error after you move or replace a virtual disk drive file of a hyper-v virtual machine.

An error occurred while attempting to start the selected virtual machine(s).
‘TestVM’ failed to start.
Microsoft Emulated IDE Controller (Instance ID
{83F8638B-8DCA-4152-9EDA-2CA8B33039B4}): Failed to Power on with Error ‘General
access denied error’
IDE/ATAPI Account does not have sufficient privilege to open attachment
‘D:\VM\TestVM\TestVM.vhd. Error: ‘General access denied error’
Account does not have sufficient privilege to open attachment
‘D:\VM\TestVM\TestVM.vhd. Error: ‘General access denied error’

This is because the permissions on the new virtual hard drive (D:\VM\TestVM\TestVM.vhd in this case) are incorrect. Here is the steps to fix this permission file.

  1. Open Hyper-V manager, Right click settings of the virtual machine,
  2. Find the Virtual Hard Drive and choose "Remove".
  3. Re-add the same Virtual Hard Drive back to the machine.
  4. Now start the VM again, it should boot successfully.

IIS 7.5 Error The temp directory in chart handler configuration is not accessible

If you build a web application with Chart control for ASP.NET 4.0 and deploy the site to web server.  You might get following error on the live site:

The temp directory in chart handler configuration is not accessible

To resolve this, first go to web.config and find the ChartImage directory in appsettings.

<appSettings>
<add key="ChartImageHandler" value="storage=file;timeout=20;dir=c:\TempImageFiles\;" />
</appSettings>

The go to the temp chart image directory and grant read and write permission to IIS working process account in share properties – security tab. Note that the account runs IIS working process is different between IIS 7 and IIS 7.5

  • On Windows Server 2008 has IIS7, grant Read and Write permission to Network Service
  • On Windows server 2008 R2 has IIS 7.5, grant Read and Write permission to AppPool\<PoolName>. Replace <PoolName> to the actual machine pool your site is running on, for example, if your site is running on pool named ASP.NET v4.0, then the account you need grant permission would be IIS AppPool\ASP.NET v4.0, you can refer this step by step instructions for detail

iPhone Tips–Change Calendar TimeZone

When you move or trip to other timezone, iPhone won’t refresh the timezone information in to correct one, this results calendar syncs to Exchange server still on the old timezone and all meetings show wrong start time than they are. To fix this, go to Settings => Mail, Contacts, Calendars =>Calendars => Time Zone Support,  either turn it off or set to proper TimeZone

Could not load file or assembly TraceWrapper, Version=1.0.523.0

There are two versions of the TraceWrapper.dll in SCVMM install CD. One is x86 version and the other is x64 version. When you build your application on top of SCVMM library Microsoft.SystemCenter.VirtualMachineManager, it’s very important to pick up the correct version TraceWrapper.dll. In general, you should copy the 32 bit dll if you are using 32 bit system, copy 64 bit dll if you are using 64 bit system. Otherwise following BadImageFormatException would occur during runtime.

Could not load file or assembly ‘TraceWrapper, Version=1.0.523.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35′ or one of its dependencies. An attempt was made to load a program with an incorrect format.

However, you should keep using 32 bit TraceWrapper on a 64 bit system for following scenarios:

  • You need debug your app in Visual Studio directly. In this case, process launched from Visual Studio debugger runs in WOW64 mode.
  • IIS is configured to run in 32 bit mode. In this case, all working processes run in WOW64 mode.

This is because in 64 bit windows, processes in WOW64 mode are 32 bit processes and can’t load 64 bit TraceWrapper.dll.

CSharp – Get Assembly and File Version

If you want to know the version of currently executing managed assembly, you can use Reflection.Assembly.

Here is code snippet which can be used to do get managed assembly version.

private string GetVersion()
{
      return Assembly.GetExecutingAssembly().GetName().Version.ToString();
}

Windows Server 2008 R2 with SP1 ISO download

After Microsoft releases Windows 7 / Windows Server 2008 R2 Service Pack 1 to public, Microsoft now provides single evaluation media ISO for Windows Server 2008 R2 with Service Pack 1 for free download. To download the official ISO just access http://technet.microsoft.com/en-us/evalcenter/dd459137.aspx and logon with your windows live ID.

Or use this Direct Download Link

File Name:  7601.17514.101119-1850_x64fre_server_eval_en-us-GRMSXEVAL_EN_DVD.iso

File Size: 2.9GB

And don’t forget to checkout this tip Exceed Windows Server 2008 R2 Trial Period

SQL Server 2005 The full-text search service cannot start

After you install SQL Server 2005 RTM on windows server 2008, the full-text search service cannot start. This is because the full-text search service depends on the NTLMSSP (NTLM Security Support Provider) service but the NTLMSSP service does not exist on Windows Server 2008.

To resolve this problem, simple install SQL Server 2005 SP3

SQL Server 2005 SP3 can be downloaded from http://www.microsoft.com/downloads/en/details.aspx?FamilyID=ae7387c3-348c-4faa-8ae5-949fdfbe59c4