c# - Different DLL but should be the same in console application and website -
i have console application , website use same system.runtime.serialization.primitives.dll
assembly. however, when run website, assembly 1 on right, if run consolation application, dll website turns 1 on left , causes errors. both projects v4.7 , started happening after upgraded projects framework.
both projects have in it
<dependentassembly> <assemblyidentity name="system.runtime.serialization.primitives" publickeytoken="b03f5f7f11d50a3a" culture="neutral" /> <bindingredirect oldversion="0.0.0.0-4.1.2.0" newversion="4.1.2.0" /> </dependentassembly>
ways solve issue different referencing of same dlls:
step 1: create new web app on visual studio 2015
step 2: check if issue still persists in new web app project.
if answer no , issue not persist more, then:
step 1: track assembly reference, causing issue, in original website (your first/buggy web application) project references section.
step 2: remove reference
step 3: add new reference , refer assembly browse option instead of checking available one. (best if can copy assembly dll reference path console project, working)
step 4: clean , rebuild project.
if issue still persists it's issue framework upgrade, have performed.
if issue resolved yay, have solved it!
now, if issue did not persist in new web app project, have created, remains in old website/app then means initial issue due corrupted referencing of dll after framework upgraded v4.7
even after updating reference in website/app , in newly created web app, if issue of referencing dlls still exists upgrade v4.7 framework corrupted , you may need uninstall , install (or repair framework upgrade prefer first option) framework again.
since have installed visual studio 2017 after have installed .net v4.7 on system, ide have fixed subtle issue on own. whereas visual studio 2015 installed , framework upgrade v4.7 got corrupted somehow, 2015 ide not resolve subtle issue internally.
if issue resolved uninstall 1 version of ide, no point in hogging hard disk memory keeping both visual studio 2015 , 2017 on same system. (this suggestion)
excess material:
microsoft has dedicated installer page .net framework v4.7 targeted different versions of visual studio, can accessed here: targetting .net platform. may want download fresh copy of .net framework v4.7 aforementioned link , install visual studio 2015 if wish continue vs2015.
Comments
Post a Comment