Multiple shims - adxloader.dll - custom registration/unregistration

Add-in Express™ Support Service
That's what is more important than anything else

Multiple shims - adxloader.dll - custom registration/unregistration
 
F Andr?


Guest


Hello,

I have two addins : one for Office applications and one for IE.
These addins calls functions from our framework located in the same directory. We need to be able to enable/disable the addins separatly (some users don't want IE addin - vice/versa). Is this possible ?

I tried to rename the adxloader.dll to adxloaderIE.dll for the IE addin, without success, it still loads the "adxloader.dll.manifest".

any idea ?

thank you


Andr?
Posted 26 Jul, 2011 11:46:35 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Hi Andr?.

Why do you want to have both add-ins in one assembly? Probably you just need to develop the IE add-on and Office add-in in different projects and add the common source files as links.
Posted 27 Jul, 2011 08:26:09 Top
F Andr?


Guest


Hi Sergey,

I think I was not clear : I have 2 assemblies, one for Office and one for IE. I just want to be able enable/disable each add-in independently.
How can I achieve this ? Knowing that the assemblies have to be located on the same directory.

Actualy I use "regsvr32 adxloader.ll" to register the Office add-in.

Maybe I should use adxregistrator.exe with each add-in assembly in argument, but I tried without success (no error returned nor log created).

thank you

Andr?
Posted 27 Jul, 2011 09:21:44 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Andr?, if you want to share one loader between two add-ins, you need to add a new IE module to the Office add-in project (both add-ins should be in one assembly).

If you develop add-ins in different projects, you should use separate instances of the loader for each add-in (both IE add-on and Office add-in should be loacted in different directories).

I just want to be able enable/disable each add-in independently.

Sorry, I don't understand what you mean. In fact, Office add-ins and IE add-ons are disabled/enabled from different applications.
Posted 27 Jul, 2011 09:40:49 Top
F Andr?


Guest



If you develop add-ins in different projects, you should use separate instances of the loader for each add-in (both IE add-on and Office add-in should be loacted in different directories).


OK, that's my problem, because I don't want to duplicate all the DLL of my framework for each add-in into sub directories.

Here my installation dir :

AppDir\MyAddin1.dll (Office)
Appdir\MyAddin2.dll (IE)
AppDir\MyFramework.dll (in fact one dozen of DLL)

MyAddin1.dll and MyAddin2.dll use MyFramework.dll, so they have to be located in the same directory. Can you confirm that this is not possible (to have multiple add-ins in the same dir)?



Sorry, I don't understand what you mean. In fact, Office add-ins and IE add-ons are disabled/enabled from different applications.


You mean if I move the IE add-in to the Office add-in project (so just a single dll MyAddin1.dll) I can enable/disable the Office and IE integration independently ? And how ?

ps: when I say "enable/disable" I mean "register/unregister".

thank you

Andr?
Posted 27 Jul, 2011 10:04:52 Top
Samuel Rostro




Posts: 1
Joined: 2011-07-28
Hi,

any reply for this ? I'm having the same problematic for deployment.

thanks

Sam
Posted 28 Jul, 2011 07:50:55 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Hi Andr?,

MyAddin1.dll and MyAddin2.dll use MyFramework.dll, so they have to be located in the same directory. Can you confirm that this is not possible (to have multiple add-ins in the same dir)?

Yes, it is not possible.

You mean if I move the IE add-in to the Office add-in project (so just a single dll MyAddin1.dll) I can enable/disable the Office and IE integration independently ? And how ?

You can't register/unregister your add-ins independently even though both add-ins are located in different assemblies. It happens because you share the same loader and adxloader.dll.manifest file between two add-ins.

In this case I see the one scenario only - you need to develop your add-ins in different projects/assemblies and all shared/dependent assemblies should be deployed to the GAC folder.
Posted 28 Jul, 2011 09:35:49 Top
F Andr?


Guest



In this case I see the one scenario only - you need to develop your add-ins in different projects/assemblies and all shared/dependent assemblies should be deployed to the GAC folder.


OK thank you Sergey, I'll dig the GAC solution.


Andr?
Posted 28 Jul, 2011 09:53:45 Top
Andrei Smolin


Add-in Express team


Posts: 18827
Joined: 2006-05-11
Hello Andr?,

May I ask you to keep us informed about your results?


Andrei Smolin
Add-in Express Team Leader
Posted 29 Jul, 2011 06:06:21 Top
F Andr?


Guest


Hello Andrei,

finally I'll not do the GAC deployment because a Strong Name is needed and I can't do that right now.
So I'll dupublicate all the needed DLLs in a separate directory for the IE Explorer Add-in. Fortunately the size of the MSI is not increased (already 46MB) since the source file references are the same. Just the targeted APPDIR is larger but this is not a big deal.


Andr?
Posted 04 Aug, 2011 08:21:47 Top