Dll

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How do you create an activeX dll (one that you can use in Microsoft access, Excel, or other Windows applications)? I've tried to use the Class Library, created the DLL, then used access to reference this dll, but when I do I get the error: "Can't add a reference to the specified file"

Thanks in advance!
 
Doug said:
How do you create an activeX dll (one that you can use in Microsoft
access, Excel, or other Windows applications)? I've tried to use the
Class Library, created the DLL, then used access to reference this
dll, but when I do I get the error: "Can't add a reference to the
specified file".

..Net DLL are assemblies, not COM DLLs - by default.

see:
http://msdn.microsoft.com/library/en-us/cpguide/html/cpconexposingnetframeworkcomponentstocom.asp

http://msdn.microsoft.com/library/en-us/vbcon/html/vbconCOMInteropInVisualBasicVisualC.asp

http://msdn.microsoft.com/library/en-us/vbcn7/html/vaconCOMInteroperability.asp


--
Armin

How to quote and why:
http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html
 
* "=?Utf-8?B?RG91Zw==?= said:
How do you create an activeX dll (one that you can use in Microsoft
access, Excel, or other Windows applications)? I've tried to use the
Class Library, created the DLL, then used access to reference this dll,
but when I do I get the error: "Can't add a reference to the specified
file".

You will have to register it for COM interop. Basic sample:

<URL:http://dotnet.mvps.org/dotnet/samples/codingtechnique/downloads/MyComLib.zip>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top