ASP.NET Interview questions


Total available count: 47
Subject - Microsoft Technologies
Subsubject - ASP.NET

What is view state?

View state is a property of a page and controls to store the values across the round trips. This value will be stored in the form of hashed string in one or more hidden fields that depends on the MaxStateFieldLength property. When the page is posted back to the server, the page parses the view-state string at page initialization and restores property information in the page.

Example:-
To store the value in the view state.
Viewstate["SlightbookViewState"] = "Slightbook";

To access the value from a view state in the form of string.

string sb = Viewstate["SlightbookViewState"].ToString();

 

 
 



Next 5 interview question(s)

1
What is the difference between user control and custom control?
2
Explain about Master pages?
3
Explain about directives in ASP.NET?
4
Common properties in all validation controls?
5
Explain about different validation controls available in ASP.NET?