DLL Server in .Net? Possible?

Mark Wills

Member
Joined
Jul 11, 2004
Messages
13
Location
Worldwide
Programming Experience
10+
Hello,

Is it possible to create a DLL in its own process with .Net?

I want to write a DLL that handles connections to a database by different applications on the same machine.

It strikes me the best way to do it is to write a DLL that connects to the database, and makes this connection available to the other applications.

Of course, when the other applications instantiate the DLL, they should all connect to the SAME instance of the DLL (because it has the connection to the database) - I don't want multiple instances of the DLL (and therefore multiple connections).

Is this possible? Any information/pointers/articles would be much appreciated. In the old days of COM, we would have called this an Out-Of-Process server... I'm not sure the same thing exists in .Net... Maybe I have to write a windows service, and use remoting?

Regards

Mark Wills
 
Last edited:
Out-Of-Process DLL .Net

Dear Wills,

You can not have Out Process dlls in .Net as you have in VB6. Therfore it is not easy to share same data with different processes.

These are some ways through which you can share data with other process as like activeX exe server.

1. Memory Mapped Files(Fastest but not directly included in .Net Framework classes)

(These are some slow techneques)
2. Web Services
3. Remote Procedure Calling

Thanks and Regards,
Gaurav
 
Back
Top