Pages

28 Sept 2012

Design a Classical WebPart


1. Add a reference "System.web"
    Then you will get the following namespaces
    System.Web.UI;
    System.Web.UI.WebControls;
    System.Web.UI.WebControls.WebParts;

2. We should inherit the class from "WebPart" base class

3. WebPart base class contains the methods like CreateChildControls( ) and  
    Render(HTMLTextWriter writer).

    CreateChildControls( ) is a method is useful  to create controls with in a  
    WebPart  and Render( ) method is used for rendering the content on the
    webpage.

4. we can override these two methods







No comments:

Post a Comment