在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
转贴:http://www.yaosansi.com/post/893.html
在WebForm1页面上直接放置用户控件WebUserControl1时的事件顺序: WebUserControl1_Init WebForm1_Init : OnInit WebForm1: Loading controls WebUserControl1_Init : OnInit WebForm1: added to Controls WebForm1: LoadViewState WebUserControl1: LoadViewState WebUserControl1: LoadPostData Begin WebUserControl1: LoadPostData End WebForm1_PageLoad: OnLoad after base's Onload. WebUserControl1_Load: after base's OnLoad iWebUserControl1: RaisePostDataChange WebForm1: OnPreRender WebUserControl1: OnPreRender WebForm1: SavedViewState WebUserControl1: SaveViewState
在WebForm1页面的Page_Load方法中用代码Load用户控件WebUserControl1时的事件顺序: WebForm1_Init : OnInit WebForm1: LoadViewState WebForm1_PageLoad: OnLoad after base's Onload. WebForm1: Loading controls WebUserControl1_Init : OnInit WebUserControl1: LoadViewState WebForm1: added to Controls WebUserControl1_Load: after base's OnLoad WebUserControl1: LoadPostData Begin WebUserControl1: LoadPostData End iWebUserControl1: RaisePostDataChange WebForm1: OnPreRender WebUserControl1: OnPreRender WebForm1: SavedViewState WebUserControl1: SaveViewState
在WebForm1页面的Button1_Click事件中用代码Load用户控件WebUserControl1时的事件顺序: WebForm1_Init WebUserControl1又在Page_Load事件中用代码Load用户控件WebUserControl2时的事件顺序: WebForm1_Init |
请发表评论