HAMMER33333
asked on
DLLs in VB .Net?
I want to create a DLL in VB .Net that can be used by other programming languages. I realize the Framework will need to be installed in order for the DLL to run. The DLL needs to expose functions, subroutines, classes, etc. I created a new project as a Class Library, put a Public declared subroutine in it, but when I reference it from another VB .Net program, I cannot get to the subroutine and it is telling me it must be "Shared". Do I need to make everything in the Class Library project shared?
I want all the items I deem necessary to be exposed to any program that uses this DLL. Are there any steps published on how to do this?
Thanks in advance,
Hammer
I want all the items I deem necessary to be exposed to any program that uses this DLL. Are there any steps published on how to do this?
Thanks in advance,
Hammer
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
>can I then take the DLL and reference it in other non-.Net programs?
non .NET programs? You can use COM interop to call managed code from VB 6 or VC++... I've never tried it.
http://www.programmersheaven.com/articles/arun/interop2.htm
non .NET programs? You can use COM interop to call managed code from VB 6 or VC++... I've never tried it.
http://www.programmersheaven.com/articles/arun/interop2.htm
Looking at that, I would think you would have to create a class that other clients could instantiate.
ASKER
If I go with the Module, which by the way is a great idea, can I then take the DLL and reference it in other non-.Net programs? OR are there other things I need to do in order to make this possible? I want this to be part of the functionality of this DLL.
Thanks,
Hammer