Jump to content
Xtreme .Net Talk

VB6 DLL works great in VB6 but not in .Net


Recommended Posts

Guest klabranche
Posted

I wrote a network enumeration DLL using API calls like NetEnumServer ect... Everything works wonderfully in VB6. I wrapped up the functionality in a DLL and tried to create a .Net example using the COM DLL. Now I am getting an invalid parameter or Browser not available error when I call the method that uses the NetEnumServer API call. Everything is the same except for .Net. Otherwise, I am using the same computer, same DLL, and practically the exact same code to call this method in .Net as I did in VB6. The only difference in .Net is the syntax changes. Anybody have any idea why the NetEnumServer API would crash in VB.Net even when being called from a VB6 COM object?

 

Kevin

:confused:

Guest klabranche
Posted
System.Net won't do it and System.Management only works with Active Directory Enabled networks and WMI (To my knowledge)..... Our network is still mostly NT4 based so ADSI won't work and every attempt using WMI to do this for me has failed. Ofcourse, I have never messed with WMI API at all and the help on it has been horrible. I could very easily be missing it.....

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...