Sunday, June 22, 2014

SharePoint Webpart Life cycle events

SharePoint Webpart Life cycle events

Event
 Source
Description
OnInit
 Control
 Fired after initialization.
OnLoad
 Control
 Fired after loading is completed.
CreateChildControls
 Control
 Creates child controls.
EnsureChildControls
 Control
 Called to ensure that CreateChildControls has executed.
OnPreRender
 Control
 Fired after all internal processing and before the controls render. This is the last step you can use to modify controls.
PreRenderComplete
 Page
 Fires if the page is executed asynchronously , and shows that rendering can be completed.
Render
 Control
 Renders the Web Part,  including the outer elements and chrome. RenderContents Control Renders the Web Part inside the outer elements and with styles,  but no chrome


Page Life cycle vs Webpart Life cycle


No comments:

Post a Comment