I am getting following issue
Could not load file or assembly 'NLog, Version=2.0.1.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
More information
=== Pre-bind state information ===
LOG: DisplayName = NLog, Version=2.0.1.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c
(Fully-specified)
LOG: Appbase = file:///C:/MyProj/XX.XXX.TempProj/
LOG: Initial PrivatePath = C:\MyProj\XX.XXX.TempProj\bin
Calling assembly : MyProj.CallingLayer, Version=1.2.1.1, Culture=neutral, PublicKeyToken=57732cb8f5e77948.
===
LOG: This bind starts in default load context.
LOG: Using application configuration file: C:\MyProj\XX.XXX.TempProj\web.config
LOG: Using host configuration file: \\corp.corpcommon.com\users\EXXXX\MY Documents\IISExpress\config\aspnet.config
LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config.
LOG: Post-policy reference: NLog, Version=2.0.1.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c
LOG: Attempting download of new URL file:///C:/Users/EXXXX/AppData/Local/Temp/Temporary ASP.NET Files/vs/39ab25b3/cbea207a/NLog.DLL.
LOG: Attempting download of new URL file:///C:/Users/EXXXX/AppData/Local/Temp/Temporary ASP.NET Files/vs/39ab25b3/cbea207a/NLog/NLog.DLL.
LOG: Attempting download of new URL file:///C:/MyProj/XX.XXX.TempProj/bin/NLog.DLL.
WRN: Comparing the assembly name resulted in the mismatch: Major Version
ERR: Failed to complete setup of assembly (hr = 0x80131040). Probing terminated.
I tried to install and uninstall Nlog using nuget but its not helping. i tried to change web.config like
<dependentAssembly>
<assemblyIdentity name="NLog" publicKeyToken="5120e14c03d0593c" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-2.0.0.0" newVersion="4.0.0.0" />
</dependentAssembly>
I am using Nlog Version 4.0