Hi,
I am trying to instantiate a .Net class in the VB editor of MS Excel
(PE 2003) Macros.
I have added the reference to the tlb of the .Net (TestProject)
project.
I am able to create the object as
dim x as TestProject.TestClass
But the following line of code is causing a runtime error.
set x = new TestProject.TestClass
I am getting the following error
"Automation error
The system cannot find the file specified."
Please help.
Regards,
Shilpa
Bob Eaton - 15 Apr 2006 04:23 GMT
You added a reference to the TLB file in Excel, but where is the DLL? The
same folder as the TLB?
It's probably having trouble finding it... I do this with a .Net assembly
that is both in the folder where the .tlb file is located (which also
happens to be in the path, though I don't think that helps with .net
assemblies) as well as in the global assembly cache and it works fine.
Bob
> Hi,
>
[quoted text clipped - 15 lines]
> Regards,
> Shilpa