Excel COM References

b33fy

New Member
Joined
Mar 8, 2011
Messages
5
Hi Guys,

Hope someone can assist.
- We have a custom DLL written in C#. The setup exe Registers the Type Library for the DLL on the users PC.
- We also have an Excel Macro Enabled Workbook which references to this TLB file.

The issue I am experiencing is when I create a new Excel Macro Enabled file and add references to the TLB it keeps track of the Version on my local PC. So when I send this to someone else in the organisation if they do not have the exact same version of the TLB it will return with a Missing Reference. I can understand why it does this but not idea in our situation.

Manual Fix
========
For the user, in Excel, if we Remove the Reference then add it back in (pointing to their local version) this fixes it but it has to be done manually.

Question
=======
Is there a way to Remove and Add a Reference in c# code (not VBA code)? Or open to any ideas on how to manage this. Please keep in mind rolling out the new DLL everytime there is a new version and re-registering the type library to everyone is not feasible for our situation.

Thanks

B
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
Hey Everyone,

Just wondering how do software coys that deploy a new version of an Excel Add-In deploy it. I would think that somehow they would need to update the references in Excel to point to the new versions.

Any info would be greatly appreciated.

Thanks
 
Upvote 0

Forum statistics

Threads
1,214,641
Messages
6,120,685
Members
448,978
Latest member
rrauni

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top