0

I had created mvc4 based app using vs2012 Framework 4.5

Upgraded the app to MVC5.

now it fails with:

Attempt by security transparent method 'WebMatrix.WebData.PreApplicationStartCode.Start()' to access security critical method 'System.Web.WebPages.Razor.WebPageRazorHost.AddGlobalImport(System.String)' failed

How to resolve this?

crthompson
  • 15,653
  • 6
  • 58
  • 80
TonyP
  • 5,655
  • 13
  • 60
  • 94
  • 1
    Please check out this question: http://stackoverflow.com/questions/17926552/attempt-by-security-transparent-method-webmatrix-webdata-preapplicationstartcod – nemesv Jul 05 '14 at 11:44
  • @nemesv,Thanks, of all that prescriptions.. only the steps For upgrading from Web API to Web API 2, in global.asax, change: WebApiConfig.Register(GlobalConfiguration.Configuration); to GlobalConfiguration.Configure(WebApiConfig.Register); and update the package was neccessary. – TonyP Jul 05 '14 at 12:17

0 Answers0