Link to home
Start Free TrialLog in
Avatar of Andy Brown
Andy BrownFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Creating a .NET based DLL for VBA

As an experiment, I want to create a c#/.Net DLL that I can reference from MS Access VBA.  So far, I have used two examples - but each one gives me the following error when I try to add it as a refernce:

"Can't add a reference to the specified file".

Here is one of the examples that I used: http://www.geeksengine.com/article/create-dll.html

Adding the reference would be ideal, but I could also use late binding.  However, I just need to find a starting point and figure out what I'm doing wrong.

Any help would be greatly appreciated.
Avatar of John Tsioumpris
John Tsioumpris
Flag of Greece image

Are you sure you followed the example to the letter...it has being quite some years since a tested this and it worked just fine...i have made the .dll and used it just fine on my Access application.
Did you use .NET 4?
ASKER CERTIFIED SOLUTION
Avatar of ste5an
ste5an
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Andy Brown

ASKER

Thank you, everyone, for coming back to me - I'll take a closer look.
Thank you guys (esp Ste5an).  As soon as I added:

  /codebase /tlb.

To the end - it all worked.

Thank you again everyone - that's been a big help.