Could not load file or assembly 'Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies

0

I am completely new to .net applications. I am currently working on connecting historian 5.5 and thingworx using .net SDKs. The SDKs are already developed by someone else and I'm just creating a service and trying to run the service. The service is created but when I run the console application, I have an exception being raised and it is as follows -

An exception has occurred, the process will exit: System.IO.FileLoadException: Could not load file or assembly 'Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) File name: 'Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' ---> System.IO.FileLoadException: Could not load file or assembly 'Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) File name: 'Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed'

WRN: Assembly binding logging is turned OFF. To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1. Note: There is some performance penalty associated with assembly bind failure logging. To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

at com.thingworx.Configuration.Read() at com.thingworx.Configuration..ctor() in d:\Users\salexander\Documents\Product\Edge SDKs\ProficyLibrary\ProficyHistorian6.0SP1\Source Code\ProficyConnector\Configuration.cs:line 272 at com.thingworx.proficy.ProficyConfiguration..ctor() at com.thingworx.proficy.console.Program.Main(String[] args) in C:\Users\hernandez.fs\Documents\ProficyHistorianConnector\ProficyHistorian6.0SP1\Source Code\ProficyConnectorConsole\Program.cs:line 16

It would be great if I could get a solution, I tried all the possible ways. I just have the .exe application and I dont know what I need to do? The application needs to run and the command prompt should stay idle with an option of quit.

c#
asp.net
.net
thingworx
historian
asked on Stack Overflow Feb 7, 2019 by Ankith r.m • edited Feb 7, 2019 by Fox

1 Answer

0

It looks like you are relying on Newtonsoft.Json which does not appear to be installed. Try installing that package and see if that error goes away.

Here is another SO post where this question was answered more in depth:

Could not load file or assembly 'Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed'

answered on Stack Overflow Feb 7, 2019 by MBak

User contributions licensed under CC BY-SA 3.0