Jawad Anwar

Jawad Anwar

  • NA
  • 18
  • 1.3k

Could not load type ServerSideViewStateAdapter App_Browser

Jan 31 2019 4:18 AM
Improving the performance of ASP.Net Webforms I tried a method which throw an error of Could not load type 'ServerSideViewStateAdapter'.
 
In my App_Code folder I have created a class with the same name.
  1. using System;  
  2. using System.Web.UI;  
  3. using System.Web.UI.Adapters;  
  4. namespace MyProject.App_Code {  
  5. public class ServerSideViewStateAdapter : PageAdapter  
  6. public override PageStatePersister GetStatePersister()  
  7. {  
  8. // return base.GetStatePersister();  
  9. return new SessionPageStatePersister(this.Page);  
  10. }  
  11. }  
  12. }  
and in App_Browseers I have created a file with the name of ViewStateAdapter.browser in which I'm getting an error on the
  1. <browsers>  
  2. <browser refID="Default">  
  3. <controlAdapters>  
  4. <adapter controlType="System.Web.UI.Page" adapterType="ServerSideViewStateAdapter" />  
  5. </controlAdapters>  
  6. </browser>  
  7. </browsers>  
The Error says: Parser Error Message: Could not load type 'ServerSideViewStateAdapter'.
 
I'm using VS 2013.
 
Kindly guide me regarding this error.
Thank you.

Answers (1)