WebControl - saving state! HOW?
-
This seems to have been touched on all over the web but I can't find a simple answer :mad: I have an ascx control that I am loading dynamically. The control loads fine but loses it's state information on a postback. Does anybody know of a simple article that explains how to get the UserControl to persits it's information pleeeeaaaasssseeeee :((
-
This seems to have been touched on all over the web but I can't find a simple answer :mad: I have an ascx control that I am loading dynamically. The control loads fine but loses it's state information on a postback. Does anybody know of a simple article that explains how to get the UserControl to persits it's information pleeeeaaaasssseeeee :((
Try using: In your control, override the following methods of Control LoadViewState(object savedState) http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfsystemwebuicontrolclassloadviewstatetopic.asp[^] SaveViewState() http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfsystemwebuicontrolclasssaveviewstatetopic.asp [^]