Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Could not load type 'System.Web.Mvc.ViewPage<dynamic>' in asp.net mvc2 after publishing the website

I am using asp.net mvc2 and the project is running very well from visual studio, but when I published the project shows this error. Could not load type 'System.Web.Mvc.ViewPage'

thanks

like image 475
Mazen Avatar asked Jan 13 '11 07:01

Mazen


1 Answers

Thanks Darin I found the solution. I have to add this

<pages
         pageParserFilterType="System.Web.Mvc.ViewTypeParserFilter, System.Web.Mvc, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"
         pageBaseType="System.Web.Mvc.ViewPage, System.Web.Mvc, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"
         userControlBaseType="System.Web.Mvc.ViewUserControl, System.Web.Mvc, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">

in my web.config

like image 123
Mazen Avatar answered Oct 31 '22 03:10

Mazen