Home > Allgemein > Create RegAddin.exe – Day 29

Create RegAddin.exe – Day 29


Currently i create a commandline tool called RegAddin.exe – It is redestributable in installations and has more options as RegAsm.exe – specialy it comes with a feature to register and deploy an addin only for the current user without admin privileges(1). (It works also with Build events in visual studio to replace “Register for COM Interop”) With some WIX templates it was very easy to to deploy an addin  -even for beginners-  thats the idea.

It works so far but i still face some magic from RegAsm.exe i didnt understand – and there is no documentation at all how this infrastructure works. So i use the monkey-see-monkey-do principle in virtual machines and spend limitless hours each night to understand what are the rules behind.

Currently i have 2 Addins(AnyCPU compiled)  on an 64 Bit system there totaly the same for me incl. its dependencies.
But for the first addin RegAsm.exe generate

[HKEY_CLASSES_ROOT\Wow6432Node\CLSID\{F42C9AF1-E8B5-4480-ACF3-EBF097D914E4}\InprocServer32]
@ = “mscoree.dll”

and for the second addin:

[HKEY_CLASSES_ROOT\Wow6432Node\CLSID\{F42C9AF1-E8B5-4480-ACF3-EBF097D914E4}\InprocServer32]
@= “C:\Windows\SysWow64\mscoree.dll”

The second addin is redirected to Wow but not the first addin.  I have no idea why for the moment…
Even in ILSpy/DotNetReflector i see no difference.

So thats what i do at the moment.

*Sebastian

Glossar:

(1) Since Windows 7 it is possible to register an addin without admin privileges only for the current user. The HKEY_CURRENT_USER hive key spend some special subkeys to bypass HKEY_CLASSES_ROOT. But RegAsm.exe/Visual Studio(and most Intallers) can’t handle that.

 

 

Advertisements
Categories: Allgemein
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: