VB.NET DLLs and ProgIDs
(Tuesday, February 01, 2005)
Found the following interesting discussion in the Newsgroups:
VB.NET DLLs and ProgIDs by:eliasengin@msn.com (eli)
| please...somebody answer this question.lol I have submit it to 4 forums and it seems noone can answer it.
In VB6 I had made a standard windows application (client) and a DLL (server). The client had a reference to AutoCAD application (you dont have to know AutoCAD, I just made a reference to its interface thats all). Then I could use a function of AutoCAD's interface call GetInterfaceObject(<ProgID>). Giving to the function the ProgID of my DLL's project I was able to load the DLL in memory space of AutoCAD.
Now, coming to .NET world, I created the same DLL and client application in VB.NET. But Calling my GetInterfaceObject function with the DLL's project ProgID as I used to, doesn't work.
Can anyone help what is going on? Is it because something has changed with the ProgID thing? Is it because DLLs are not registered any more?
Thanks in advance, Elias
I want to move a big application to VB.NET and I can't due to this problem
| | | Reply: by:Mattias Sjögren
| | | >I have submit it to 4 forums and it seems noone can answer it.
Perhaps because you don't supply enough information. Have you registered your library correctly? Can you instantiate objects from other COM clients? DO you get any error messages?
Mattias
-- Mattias Sjögren [MVP] mattias @ mvps.org http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com Please reply only to the newsgroup.
| | | Reply: by:eliasengin@msn.com (eli)
| | | Maybe you are righ, I dont provide enough information.
Can I register DLLs with VB.NET? I thought it was something abandoned. And if I can isnt it automatically done any more to my machine? (as I develop, like VB6?) And if it is like that will that be done in my clents machine at distribution?
The case is really simple:
I have a variable "application" with which I reference my AutoCAD application And a "server" variable with which I reference my DLL reference (I added a reference to my DLL from the references dialogbox).
Then I can write set Server=application.GetInterfaceObject(ProgID of the DLL project). The function finds the ProgID and works in VB6 fine. I can figure out what changes in .NET, but I guess the ProgID is not acceptable anymore.
(I dont remember right now the error message I get and I am away from my computer, but I can give it to you later)
Thank you very much for answering. I hope I did provide you with some extra important info
Elias
|
Posted by Xander Zelders

|
|
|
|
0 Comments:
Post a Comment
<< Home