8

I have a MVC app, I used http://nuget.org/ to install Elmah for MVC, I Was able to install it and run it successively.

After few week reopening Visual Studio I Get this error:

Could not load file or assembly 'Elmah' or one of its dependencies. The system cannot find the file specified. 


Error
<httpModules>
Line 73:       <add name="ErrorLog" type="Elmah.ErrorLogModule, Elmah" />

I tried to add a reference in the project to Elmah.Mvc but with no success. Could you point me out how to fix this problem? Thanks

GibboK
  • 68,054
  • 134
  • 405
  • 638
  • I had this issue as well and solved it by setting "Copy Local" to true – user2865446 Aug 10 '16 at 20:18
  • Had similar error, turns out I was targeting the wrong configuration and had recently added ELMAH. The ELMAH DLLs were missing from my /bin folder and IIS was pointing to Debug root. – Jason Slocomb Apr 18 '19 at 17:27

1 Answers1

12

Reinstall Elmah.Mvc via NuGet would be my advice. If this doesn't help, try reinstalling the elmah.corelibrary NuGet package (being a dependency of Elmah.Mvc).

aknuds1
  • 61,734
  • 61
  • 186
  • 308