Can you programmatically store and retrieve data from ViewState?

 Posted by Tripati_tutu on 11/12/2010 | Category: ASP.NET Interview questions | Views: 3501 | Points: 40
Answer:

Yes, you can programmatically store and retrieve data from ViewState in an ASP.NET application.

Example: To save the value in ViewState object
 ViewState("Name") = txtName.text;

Retrieve the value from ViewState object
String strName = ViewState("Name").ToString();


Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Login to post response