GAC vs *.exe.config (and %path%)

P

per9000

Hi,

suppose I want to make a .NET dll and a .NET exe that needs this dll.
If I do not want to put the dll in the same folder as the exe: do I
have to use GAC or a *.exe.config file? Are there other solutions
(putting the dll in the path does not seem to work)?

Suppose I want to distribute the dll to users (the users, also, will
not use the same folder) and the source code to the exe to let them
build stuff on their own - what is the best solution: GAC or
*.exe.config or some other solution?

Thanks,
Per Erik Strandberg
 
G

Guest

If dll's will be shared amoung more than one app on a machine then GAC them.
this is what the GAC is for.
If the dlls are only for use in one app then you can put them in the bin
folder (or use the config [or potential manifest, i cant remember now] to
redirect the assembly prober to look in other places.). You can still GAC
them for a single app.
In real world terms, control libraries and things for developers should be
GAC'd as you/they may want to install new versions but also keep using the
old versions sometimes. For dlls like business layer dlls or things like that
for a fat client app, use the bin folder as the app will always want the
newest version.

HTH
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top