Sometimes you need to modify the assembly at runtime without recompiling everything. What you can do it quickly
including bindingRedirect item web.config.
For example, suppose you need to redirect a dll (Oracle.DataAccess) especially from an older version to a newer version.
The following code shows how to redirect the version 10.1.0.200 to 10.2.0.100:
\u0026lt;configuration>
\u0026lt;runtime>
\u0026lt;assemblyBinding xmlns = "urn: schemas-microsoft-com: asm. v1 ">
\u0026lt;dependentAssembly>
\u0026lt;assemblyIdentity name="Oracle.DataAccess" publicKeyToken="89B483F429C47342"
culture="neutral"/>
\u0026lt;bindingRedirect oldVersion="10.1.0.200" newVersion="10.2.0.100"/>
\u0026lt;/ dependentAssembly>
\u0026lt;/ assemblyBinding>
\u0026lt;/ runtime>
\u0026lt;/ configuration>
This avoids adding the new reference and recompile the solution.
0 comments:
Post a Comment