Visual Basic .NET » Internet / Hardware Communication
Multiple DLL exists at installation -- Prateek --


Hi,

I have just started doing my .net application development and I have one question related to installation of the assembly.

I have created 2 dlls, say a.dll and b.dll I have created one exe which refers to both the dlls i.e. a.dll & b.dll I have created another exe which referes to just one dlls i.e. a.dll created 2 different setup for both the exe so that it get installed in different directory say c:\app1 and c:\app2

Now problem I am having is that there multiple dll exists in each installed directory. i.e. a.dll exists in C:\app1 and c:\app2 direcotry. What I really want is that, these dlls (a.dll & b.dll) are my servers which needs to be installed in one direcotry and these exe should use the dlls installed in the central location.

Can anybody help what I should be doing and what am i doing wrong.

Regards,

pb.

-- BradleyPeter --


You have a number of choices.

If you want your server to run remotely (i.e. not necessarily on the same machine or in the same process as the clients) you should consider
.NET remoting or Web Services.

If your clients and servers will always be on the same machine, running in the same process, then you can give your servers strong names and put them in the GAC. There will be no need for copies of the servers in the folders with the executables in that case.

By default, .NET will put copies of all referenced DLLs in the same folder as the executable. However, at runtime, the .NET Framework looks for the DLLs in the GAC first and then in the same folder as the executable. So if your servers are in the GAC, you won't need the copies in the executables' folders.

You do need to give your assemblies strong names, though, if you're going to put them in the GAC.

There are a few more wrinkles than that, but this should be enough to get you started, I hope.

HTH
Peter
-----Original Message-----
From: DotNetDevelopment
Multiple DLL exists at installation
Hi,

I have just started doing my .net application development and I have one question related to installation of the assembly.

I have created 2 dlls, say a.dll and b.dll I have created one exe which refers to both the dlls i.e. a.dll & b.dll I have created another exe which referes to just one dlls i.e. a.dll created 2 different setup for both the exe so that it get installed in different directory say c:\app1 and c:\app2

Now problem I am having is that there multiple dll exists in each installed directory. i.e. a.dll exists in C:\app1 and c:\app2 direcotry. What I really want is that, these dlls (a.dll & b.dll) are my servers which needs to be installed in one direcotry and these exe should use the dlls installed in the central location.

Can anybody help what I should be doing and what am i doing wrong.

Regards,

pb.


-- Prateek --


Thanks for suggestion.

This is enough for me to start digging more in details with different option

[Submit Comment]Home