0

I have an asp.net MVC 4 web application which is running fine on developer machine(i have hosted it in IIS). But after hosting in to another machine which doesn't have mvc framework installed and .net framework installed, i ended up with the following

Could not load file or assembly 'Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The system cannot find the file specified

i came know to know that mvc framework is not required to host, from the below link

Do I need to install MVC 3/4 on web server to run mvc application

Community
  • 1
  • 1
vallabha
  • 385
  • 1
  • 12
  • Make sure you've correct version of Newtonsoft.Json in your dll – Mox Shah Nov 14 '14 at 04:17
  • @MokshShah i don't have Newtonsoft.Json dll in bin folder but as i mentioned it is working in developer system after hosting in IIS – vallabha Nov 14 '14 at 04:28
  • Are you using it? then it must be in your bin/debug folder. what best you can is, go project referenced and check from where it's referenced and get a copy from that path and put it in your bin folder(in another machine where its not working) – Mox Shah Nov 14 '14 at 04:32
  • @MokshShah I'm not using it any where in my project i think it is the default json serializer for mvc – vallabha Nov 14 '14 at 04:37

2 Answers2

0

Nope its not a default one, verify once in your project references, it must be referenced. Newtonsoft is third parth library, so its no by default in project, go through all your project's references and look for Newtongsoft.Json, once you find remove it or If you're using packages then go to your package.config file and lookfor Newtonsoft.Json and remove it

Mox Shah
  • 2,967
  • 2
  • 26
  • 42
0

Try to remove the Newtonsoft Json Nuget (uninstall-Package Newtonsoft.Json) package or

install The Newtonsoft Json (Install-Package Newtonsoft.Json) then Uninstall it, it may works