The name 'ViewState' Does Not Exist in the Current Context

Say you have something like ViewState("AccountID") in a c# page when trying to use Viewstate.  It will give the error "The name 'ViewState' Does Not Exist in the Current Context".  What is incorrect about the code is you should be using "ViewState["name"]".  Encountered that error from a page conversion to C#.

Comments

Popular posts from this blog

Asp.net Publishing Broke Site - "App_WebReferences is not allowed because the application is precompiled"

Telerik - Custom Group Footers In RadGrid

Bootstrap Modal Popup is Grayed Out