Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel VBA compilation

Status
Not open for further replies.

christhedonstar

Programmer
Apr 9, 2007
215
GB
Hi,

I have some code which uses a com addin (c# with a tlb).

On a machine without the the com dll when I open the sheet it complains that a reference is missing (am using early binding).

Whats odd is that we thought that excel will only compile the vba it needs to compile before it runs it. Indeed in the workbook open event we have code to get the com dll and register it so that the excel application can function.

What is weird is that if we cut down the amount of VBA code that uses the dll we don't get the session complaining that the reference is missing when the workbook is opened.

Any idea what is going on here? Anyone understand exactly how the compilation process works in Excel?

Thanks,

Chris
 
The whole VBAProject should compile properly.
I'd use late binding.

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top