I've been writing this program(FOO
), and it includes a reference to a dll(BAR
). All BAR
contains is methods which perform various different calculations. FOO
will be able to be installed and deployed on multiple computers. My question is, if I change a formula in one of the methods(i.e. change x + y
to x - y
), will I need to rebuild FOO
against the new BAR
? More importantly, is it safe to just deploy the new version of BAR
?
Open the project in Visual Studio. Right-click on the project's References folder and select Add Reference to open the Add Reference dialog box. Locate the new assembly version in the Add Reference dialog for each Infragistics assembly listed in your References folder.
A reference is essentially an entry in a project file that contains the information that Visual Studio needs to locate the component or the service.
To add a reference in Visual Studio, right click the "references" folder > choose "add reference" and then "Browse" to you DLL.
@vcsjones's comment raises an important point here.
You can drop in a new DLL as a replacement if and only if the assembly version does not change and you are not using strong named assemblies.
If the version does change then you may receive runtime errors because your program tries to load a specific version and gets a different version than it expects. This may however work fine if no method signatures have changed but I wouldn't guarantee it and would always recommend a recompile.
This is even more of a problem when using strong named assemblies since the strong name encodes both the version and a digital signature of the assembly. So if any code has changed in the assembly then the digital signature will change even if the version has not, hence the strong name changes.
Again this will cause runtime errors because the strong name your program expects will not match the assembly strong name. So in this case a recompile is always required.
To summarize:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With