Ismo
Go to VB Editor, open tools menu/references.., and put a check mark against "Microsoft Visual Basic for Applications Extensibility".
Celia
I mean how can I do this in VB-macro ?
Ismo
I believe you use the AddFromFile method. Here's a line I used in an MSWord macro to accomplish the same thing:
ActiveDocument.VBProject.References.AddFromFile "[directory]\VBEEXT1.olb"
You'll have to adjust the above for Excel object references.
Is that what you're looking for?
Tom
ActiveDocument.VBProject.References.AddFromFile "[directory]\VBEEXT1.olb" You'll have to adjust the above for Excel object references. Is that what you're looking for?
Yes that's what I want! Thank You !
Ismo
BTW: Maybe AddFromGuid "{...}" is better because Office/Excel may be
in different directory in different machines
Ismo - How do you determine the GUID for a library file of interest? After rattling around VBE and VBA help, the truth was, as usual, shrouded in mists. Did you get AddFromGuid working?
Tom
I run regedit and find data "VBEEXT1.olb" and take value on it.
I don't understand anything about GUID but value is same with
two tested machine.
It works on my NT4.0 and Win98 with Office97 but I think
it don't work with Office2000 because
AddFromGuid needs some version parameters?
Ismo