| « Scrolling an InkCollector | Are you a button guy? » |
Be careful when installing VS add-ins in localized Windows versions
31/01/06
Be careful when installing VS add-ins in localized Windows versions
When installing add-ins for Visual Studio, a number of different paths can be used. One of them is C:\Documents and Settings\All Users\Application Data\Microsoft\MSEnvShared\Addins - in a default installation of a US English Windows. Obviously a proper installer would use Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData) to make sure the path is correct for the current system and for the current language. For example, for a German system the result would be C:\Dokumente und Einstellungen\Alle Benutzer\Anwendungsdaten\Microsoft\MSEnvShared\Addins.
Now, the funny thing is that a part of the path is stored by Visual Studio verbatim. To be precise, VS stores the path as %ALLUSERSPROFILE%\Application Data\Microsoft\MSEnvShared\Addins, as you can see in VS using Tools/Options/Add-in/Macros Security.

Obviously they forgot that the Application Data part wouldn't be called that in a localized version of Windows. So if you want to install your add-in into that path, you should make sure you fiddle around with it to create a mixed-language version, which fits the template used in the VS settings.
2 comments
Stefan


