Monday, July 26, 2010

Asp.Net StartupGuide

1.What is the difference between login controls and Forms authentication?

• Forms authentication can be easily implemented using login controls without writing any code.
• Login control performs functions like prompting for user credentials, validating them and issuing authentication just as the FormsAuthentication class.
• However, all that’s needs to be done is to drag and drop the use control from the tool box to have these checks performed implicitly.
• The FormsAuthentication class is used in the background for the authentication ticket and ASP.NET membership is used to validate the user credentials.


2. Define Session, SessionId and Session State in ASP.NET.
A session is the duration of connectivity between a client and a server application.

SessionId is used to identify request from the browser. By default, value of SessionId is stored in a cookie. You can configure the application to store SessionId in the URL for a "cookieless" session.


3. Explain the ASP.NET page life cycle.
Lifecycle of a page in ASP.NET follows following steps:
Page_Init(Initialization of the page) >> LoadViewState(loading of View State) >> LoadPostData(Postback data processing) >> Page_Load(Loading of page) >> RaisePostDataChangedEvent(PostBack change notification) >> RaisePostBackEvent (PostBack event handling) >> Page_PreRender (Page Pre Rendering Phase) >> SaveViewState (View state saving) >> Page_Render (Page rendering) >> Page_UnLoad (Page unloading)


4. What is CLR?
CLR is .NET equivalent of Java Virtual Machine (JVM). It is the runtime that converts a MSIL code into the host machine language code, which is then executed appropriately. The CLR is the execution engine for .NET Framework applications. It provides a number of services, including:
> Code management (loading and execution)
> Application memory isolation
> Verification of type safety
> Conversion of IL to native code.
> Access to metadata (enhanced type information)
> Managing memory for managed objects
> Enforcement of code access security
> Exception handling, including cross-language exceptions
> Inter-operation between managed code, COM objects, and pre-existing DLL's (unmanaged code and data)
> Automation of object layout
> Support for developer services (profiling, debugging, and so on).