.net ViewState in page lifecycle

后端 未结 4 800
遇见更好的自我
遇见更好的自我 2020-12-21 02:30

I have a page containing a control called PhoneInfo.ascx. PhoneInfo is dynamically created using LoadControl() and then the initControl() function is called passing in an i

4条回答
  •  情书的邮戳
    2020-12-21 03:10

    ViewState is managed between the Init and Load events. You should utilize code in or functions called from the Page_Init handler instead of Page_Load when you are concerned with maintaining values from postbacks.

    See this link for more information on the ASP.NET page life cycle.

    http://msdn.microsoft.com/en-us/library/ms178472.aspx

提交回复
热议问题