Like a good developer I have been trying to run Visual Studio with least privilege; with Windows 7 this seems to work well. My main account is not an administrator, but Windows prompts me for elevated rights when needed. I have been developing happily with Visual Studio and Typemock without any need for extra rights.

However, when I have been doing some testing using Ivonna, the Typemock add-in, I hit a problem. When I tried to create an Ivonna.Framework.TestSession() I got a Licensing.LicenseException: This copy has expired. Which it hadn’t as I have a fully licensed product.

I had got so use to not needing elevated privilege I did not consider it to be the problem; so I contacted Sm-Art and Typemock support. The answer was simply to run Visual Studio with administrator privileges (right click on the short cut). Once this is done the licensing exception goes away as Typemock has enough rights to look in the right bit of the registry to access the add-in license. I have suggested that if possible this requirement needs to be addressed.

The other alternative is to grant your non administrator account more rights in the registry. On a 64bit development box it seems you need to a Read-Write access to HKEY_LOCAL_MACHINESOFTWARETypeMock and HKEY_LOCAL_MACHINESOFTWAREWow6432NodeTypeMock