Dependancy Question

  • Thread starter Thread starter solex
  • Start date Start date
S

solex

Hello All,

I have a few projects with a bunch of shared DLL's that I have created, one
depending on another and so on and so forth.

If I upgrade a lower level DLL is it possible to propagating this change to
all other projects without have to recompile all dependant projects? In VB
6 it was relatively simple and I realize that this was the "DLL Hell"
situation but I have shared DLL's that use the Singleton pattern and the
most current version must be used by all dependant projects.

Thanks,
Dan
 
Make a class library called 'DepA' that has a single function that returns
"V1", a class library called 'DepB' that has a single function that returns
the return value of the function in 'DepA', and a console application that
prints the return value of 'DepB'. Make sure the console application prints
"V1".
Then go back and change DepA to return "V2". Go back to the console
application, and what does it do?
 
Bonj,
Although I appreciate your response, I am not sure that I understand it with
respect to my original question. In your example V1 will always be
returned. My question is if I update a core dll how do I avoid getting the
following warnings assuming the core librarie's inteface does not change:

Warning: The dependency 'MyNamnSpace.CodeType, Version=1.0.1633.19278,
Culture=neutral, PublicKeyToken=6xb82b5d8dxaa417' in project 'CommEvent'
cannot be copied to the run directory because it would overwrite the
reference 'MyNameSpace.CodeType, Version=1.0.1741.25089, Culture=neutral,
PublicKeyToken=6xb82d5d8deaa417'.
 
I was trying to illustrate the simplest example that demonstrates the problem
I thought you were having... you are correct in that it returns V1, hence
doesn't automatically update with the latest version of all DLLs.
And the solution would be to manually copy the latest version of DepA into
the DepC output folder, this saves you having to recompile DepB.
I'm not sure why you're getting the warning about overwriting a newer
version with an older, so I couldn't advise how to get rid of that.
One thing you may find helpful though if you are installing the components
in the GAC, is to create a setup project. IIRC, this will automatically
retrieve the latest version of all the components into itself when it builds.
 
Back
Top