ASP.NET Question Answers

Hello friends in this post we are going to discuss about ASP.NET MCQ with answers | ASP.NET Multiple choice question with answer | ASP.NET Objective type question with answer | ASP.NET Wipro trendnxt mykskillz

If you are looking for more Dumps for MYSKILLZ Visit Here 4.5 and vs2012 fundamental

Standard controls

Webserver controls

State management

1.Disable client side validation

How to disable client side validation.


2.Property in all validation controls

What is the property present in all validation controls


3.What are the selection modes in list box?

Ans:Single ,multiple and extended

4.wat ll happen when you give listbox selected index as -1?

 List box selectedindex to-1

Ans:listbox ll get deselected(***)


5.which is client side valid-state management?

Valid stage-management

Ans:Viewstate,control state,hidden fields,querry strings,cookies

Server side state management:

Ans:Session state,Application State

6.What are all the Factor to choose state management


  • how much information do you need to store?
  • Does the client accept persistent or in-memory cookies?
  • Do you want to store the information on the client or on the server?
  • Is the information sensitive?
  • What performance and bandwidth criteria do you have for your application?
  • What are the capabilities of the browsers and devices that you are targeting?
  • Do you need to store information per user?
  • How long do you need to store the information?
  • Do you have a Web farm (multiple servers), a Web garden (multiple processes on one machine), or a single process that serves the application?

7.What are all true about Application cache


Internet Explorer 10 and Windows Store apps using JavaScript support the Application Cache API (orAppCache), as defined in the HTML5 specification, which allows you to create offline web applications. AppCache enables webpages to cache (or save) resources locally, including images, script libraries, style sheets, and so on. In addition, AppCache allows URLs to be served from cached content using standard Uniform Resource Identifier (URI) notation.

By using AppCache to save resources locally, you improve the performance of a webpage by reducing the number of requests made to the hosting server; you also enable offline access to cached resources.

To cache resources locally:

1. Create a manifest file that defines the resources you want to save.

2. Reference the manifest file in each webpage designed to use cached resources.

  • The CACHE: section defines resources that will be stored locally. In this example, three files are cached.
  • The FALLBACK: section defines resources to be used when other resources are not available. For example, this example defines figure2.png as a fallback image for the photos folder. If the browser cannot access images in the photos folder (because the browser is offline or because the server cannot be reached), figure2.png will replace the unavailable images in the rendered markup. As a result, figure2.png will be cached locally.
  • The NETWORK: section specifies resources to be accessed when there is a network connection. Resources in this section are not cached. This section allows the use of the wildcard (*) character to indicate that all other resources should not be cached.

Manifest files can contain any number of these sections and sections can be repeated; however, new sections must begin with the section header followed by a colon, as shown in the previous example. If no section header is provided, the CACHE: header is presumed. The following example shows a simplified manifest.


In addition, manifest files:

  • Must be encoded with 8-bit Unicode Transformation Format (UTF-8) character encoding.
  • Must be served with a text/cache-manifest MIME type.
  • Must begin with the line “CACHE MANIFEST”.
  • Can contain comments, preceded by the pound sign (#).

8.What are all true about User control and custom control


Web user controlsWeb custom controls
Easier to createHarder to create
Limited support for consumers who use a visual design toolFull visual design tool support for consumers
A separate copy of the control is required in each applicationOnly a single copy of the control is required, in the global assembly cache
Cannot be added to the Toolbox in Visual StudioCan be added to the Toolbox in Visual Studio
Good for static layoutGood for dynamic layout

9.Partial page caching

If page output caching________caching persist a page to load half and create dynamically

Ans:partial page caching

10.Cookies where stores

Ans:stored as text file in local computer

Or  stored in view files in internet explorer

11.command to  clear the session


12.what ll happen if you remove session in web.config

Session remove in web.config


session will work

Session will not work

Viewstate wont work

Cookies ll not store

Ans:session will work

13.what s the base class for all pages

Base class for all pages


14.Boundary to determine web application


15. Mobile ui supports

Ans:Mobile page***

16:How to add reference to a solution

Add reference

Ans:right clickàadd referenceàchoose appropriate path



Ans:<!- -include path=”filename”–>

18.Syntax for directive

Ans: <!- -include path=”filename”–>

19.Property has by all validator


20.Caching used in user control


User control caching in ASP.NET is called fragment caching. It’s done by adding an OutputCache directive to the top of your page: <%@ OutputCache Duration=”120″ VaryByParam=”None” %>

21. Different modes in session

  • InProcess mode, which stores session state in memory on the Web server. This is the default.
  • StateServer mode, which stores session state in a separate process called the ASP.NET state service. This ensures that session state is preserved if the Web application is restarted and also makes session state available to multiple Web servers in a Web farm.
  • SQLServer mode stores session state in a SQL Server database. This ensures that session state is preserved if the Web application is restarted and also makes session state available to multiple Web servers in a Web farm.
  • Custom mode, which enables you to specify a custom storage provider.
  • Off mode, which disables session state.


1.what is the template in datalist control?

Header and footer template

Item template

Seperator template

2.What is the template to display data in repeater control?

  • ItemTemplateContains the HTML elements and controls to render once for each data item in the data source.
  • AlternatingItemTemplateContains the HTML elements and controls to render once for every other data item in the data source. Typically, this template is used to create a different look for the alternating items, such as a different background color than the color that is specified in the ItemTemplate.
  • HeaderTemplate and FooterTemplateContains the text and controls to render at the beginning and end of the list, respectively.
  • SeparatorTemplateContains the elements to render between each item. A typical example might be a line (using an HR element).

3.What is the standard column type in datagrid?

 columns are automatically generated using default column types appropriate for the data types contained in the bound data source.

4.What are the builtin objects in

ASP Built-in Objects

Application Object (IIS)

ASPError Object

ObjectContext Object (IIS)

Request Object

Response Object

Server Object (IIS)

Session Object (IIS)

5.unhandled errors are handled through

i)page-error ii)application error  iii)custom error in web.config iv)all the above

Ans: custom error in web.config

6.asp:label is rendered as what in IE?

i)label  ii)span iii)div  iv)table


7.what method is triggered when page object release memory?

Ans:Disposed or UNLOAD

8.By what property we can find the Postback condition?

Ans: IsPostBack is a property of the Asp.Net

3)Required attributes:mode

Optional Attributes:timeout,cookiless, stateConnectionString, sqlConnectionString, stateNetworkTimeout

8)all the above



1)Default authentication maode

2)when postback occurs?

3)how to add reference

4)Which will not create server side event?

Hint:mouse move,txt change,btn click

5)Directives in

6)include directive

7) authentication

8)Which property is used to display the control to user


9)Mobile UI controls

10)Template in repeaters

11)session state modes

12)Valid type state management

13)View state concept

Hint:hidden field,postback,event generation,serverside controls

14)partial page caching

15)what will happen if you remove session from web.config?

16)session state modes

17)parameters of session in web.config

18)can we ve more than one validator in server control

19)user control/Custom control

20)Method to remove one item at a time in listbox


To disable validation in a specific control

Set the control’s CausesValidation property to false.

To disable a validation control

Set the validation control’s Enabled property to false.

To disable client-side validation

Set the validation control’s EnableClientScript property to false.

Leave a Reply

Your email address will not be published. Required fields are marked *