Welcome PradhiKarthik: Interview Questions

Monday, September 20, 2010

Interview Questions

.NET INTERVIEW QUESTIONS
    (Including  .NET 3.0 , AJAX/ATLAS , Vista series(WCF / WPF / WWF) ,UML,Architecture,Project Management ,SQL Server , Sample project and General Interview Questions  )

    (B) What’ is the sequence in which ASP.NET events are
    processed ?
    Following is the sequence in which the events occur :-
    √       Page_Init.
    √       Page_Load.
    √       Control events
    √       Page_Unload event.
    Page_init event only occurs when first time the page is started, but Page_Load occurs in subsequent request of the page.
    (B) In which event are the controls fully loaded ?
                     Page_load event guarantees that all controls are fully loaded. Controls are also accessed in Page_Init events but you will see that viewstate is not fully loaded during this event.
    (B) How can we identify that the Page is PostBack ?
                     Page object has a “IsPostBack” property which can be checked to know that is the page posted back.
    (B) How does ASP.NET maintain state in between
    subsequent request ?
                    Refer caching chapter.
    (A) What is event bubbling ?
                    Server controls like Datagrid, DataList, Repeater can have other child controls inside them. Example DataGrid can have combo box inside datagrid. These child control do not raise there events by themselves, rather they pass the event to the container parent (which can be a datagrid, datalist, repeater), which passed to the page as “ItemCommand” event. As the child control send there events to parent this is termed as event bubbling.
    (B) How do we assign page specific attributes ?
                   Page attributes are specified using the @Page directive.
    (A) If we want to make sure that no one has tampered with
    ViewState, how do we ensure it?
                  Using the @Page directive EnableViewStateMac to True.
    (B) What is the use of @ Register directives ?
                  @Register directive informs the compiler of  any custom server control added to the page.
    (B) What’s the use of SmartNavigation property ?
                   It’s a feature provided by ASP.NET to prevent flickering and redrawing when the page is posted back.
    Note:- This is only supported for IE browser. Project’s who have browser compatibility as
    requirements have to think some other ways of avoiding flickering.
    (B) What is AppSetting Section in “Web.Config” file ?
                  Web.config file defines configuration for a webproject. Using “AppSetting” section we can define user defined values. Example below defined is “ConnectionString” section which will be used through out the project for database connection.
    (B) Where is ViewState information stored ?
                   In HTML Hidden Fields.