Posts

Showing posts from March, 2013

Enabling anonymous access on SharePoint 2010

Enable anonymous access for the Web application. To do this follow these steps: Start SharePoint 3.0 Central Administration, and then click Application Management . Under Application Security , click Authentication providers . In the Web Application box, click the arrow, click Change Web Application , and then click the Web application that you want. Under the Zone heading, click Default to open the Edit Authentication page. On the Edit Authentication page, click to select the Enable anonymous access check box, and then click Save . Enable anonymous access for the site collection. To do this, follow these steps: Open the site collection that is hosted in the Web application in the browser. Click Site Actions , and then click Site Settings . Under Users and Permissions , click Advanced permissions . Click Settings , and then click Anonymous Access . Click Lists and libraries , and then click OK . Enable anonymous access for the resource. To do this, follo...

WebPart Life Cycle

OnInit: This event handles initialization of the control. OnLoad: This event handles the Load event. This is also used for initialize the control but is not intended for loading data or other processing functionality. CreateChildControls: This event creates any child controls. So if you are adding any control to display then you have to write in this method. EnsureChildControls: This method ensures that CreateChildControls has executed. This method must be called to prevent null reference exceptions. SaveViewState: View state of the web part saved. OnPreRender: This method handles or initiates tasks such as data loading that must complete before the control can render.  Page.PreRenderComplete: The page fires the PreRenderComplete event after all controls have completed their OnPreRender methods. Render: This method is used to render everything. RenderContents: Renders the contents of the control only, inside o...