MCQs > IT & Programming > ASP.NET MCQs > Basic ASP.NET MCQs

Basic ASP.NET MCQ

1. Which of the following attributes of the "FileUpload" control is/are introduced in ASP.NET 4.5?

Answer

Correct Answer: HasFiles

Note: This Question is unanswered, help us to find answer for this one

2. Which of the following methods is/are used for garbage collection notifications?

Answer

Correct Answer: WaitForFullGCApproach
WaitForFullGCComplete

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

3. In order to support which of the following types of HTML5. the TextMode property of a TextBox control has been updated in ASP.NET 4.5?

Answer

Correct Answer: Email

Note: This Question is unanswered, help us to find answer for this one

4. Which of the following statements is/are correct about garbage collector?

Answer

Correct Answer: It allows the programmer to create an application without having worry about free memory.
It recover the memory from no longer used Objects.

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

5. In which of the following files does ASP.NET 4.5 enables us to register the OAuth provider?

Answer

Correct Answer: App_Start/AuthConf‌ig.cs

Note: This Question is unanswered, help us to find answer for this one

6. which of the following statements about enumerations is/are incorrect?

Answer

Correct Answer: Enumerations can def‌ine their own methods.
Enumerations can implement interfaces.

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

7. In ASP.NET 4.5. what is the use of the "SoundPlayer" class of the "SystemMedia" namespace?

Answer

Correct Answer: It is used to control the playback of a sound from a .wav f‌ile.

Note: This Question is unanswered, help us to find answer for this one

8. Which of the following are new features in Windows Workflow Foundation 4.5?

Answer

Correct Answer: Ability to set breakpoints on states.
Designer support for shared trigger transition creation.

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

9. Which of the following is/are NOT interfaces of the SystemWeb namespace?

Answer

Correct Answer: lisTraceListener
XmlSiteMapProvider

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

10. Which of the following validation controls do not have the "MinimumValue" and "MaximumValue" properties?

Answer

Correct Answer: CompareValidator
RegularExpressionValidator
RequireFieldValidator

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

11. Which type of JIT compiler compiles only those methods that are called at runtime and removes them from memory after execution?

Answer

Correct Answer: Econo JIT

Note: This Question is unanswered, help us to find answer for this one

12.

Which of the following element specif‌ies whether the CLR runs garbage collection on a seperate thread?

Answer

Correct Answer:

<gcConcurrent>


Note: This Question is unanswered, help us to find answer for this one

13. Which of the following options is not a working phase of garbage collector?

Answer

Correct Answer: Distructive phase

Note: This Question is unanswered, help us to find answer for this one

14. Which of the following statement is not correct for WebSocket protocol?

Answer

Correct Answer: WebSockets support single-directional messaging.

Note: This Question is unanswered, help us to find answer for this one

15. Which of the following three main methods are available in WebSocketHandler class when programming WebSockets?

Answer

Correct Answer: OnOpen. OnMessage. OnClose

Note: This Question is unanswered, help us to find answer for this one

16. Which of the following properties doesn‘t belong to the LinkButton class in ASP.NET 4.5?

Answer

Correct Answer: AlternateText

Note: This Question is unanswered, help us to find answer for this one

17. Name the two keywords by which you can use resources in the .NET Framework 4.5 or the Windows Runtime to create an asynchronous method almost as easily as you create a synchronous method?

Answer

Correct Answer: Async and Await

Note: This Question is unanswered, help us to find answer for this one

18. ln ASP.NET 4.5, which of the following controls is used in advance caching scenarios to update some parts of the page?

Answer

Correct Answer: Substitute

Note: This Question is unanswered, help us to find answer for this one

19. Which of the following is not a method of ListBox Class in asp.net 4.5?

Answer

Correct Answer: Sort

Note: This Question is unanswered, help us to find answer for this one

20. Which of the following interfaces/classes are inherited from the Control class?

Answer

Correct Answer: lsEnabled

Note: This Question is unanswered, help us to find answer for this one

21. Which of the following Options can reduce the startup time by reducing the requirement of jitter to run at startup?

Answer

Correct Answer: Native Image Generator (NGEN)

Note: This Question is unanswered, help us to find answer for this one

22. What is the use of async and await introduced in .net 4.5?

Answer

Correct Answer: async and await are markers which mark code positions from where control should resume after a task completes.

Note: This Question is unanswered, help us to find answer for this one

23. Which of the following is NOT a method of the FormsAuthentication class in ASP.NET framework 4.5?

Answer

Correct Answer: lsEnabled

Note: This Question is unanswered, help us to find answer for this one

24. Which of the given options is not a correct portion of an external AntiXSS library that is incorporated into ASP.NET 4.5?

Answer

Correct Answer: XmlFormEncode

Note: This Question is unanswered, help us to find answer for this one

25. How many garbage collectors are required to recover the memory used by objects that have the "Finalize()" method?

Answer

Correct Answer: 2

Note: This Question is unanswered, help us to find answer for this one

26. Which of the following Options is not a parameter type in the "GC.CoIIect" method?

Answer

Correct Answer: String

Note: This Question is unanswered, help us to find answer for this one

27. Which of the following fields is NOT used within the property of Gridview data-bound control?

Answer

Correct Answer: TemplateField

Note: This Question is unanswered, help us to find answer for this one

28. Which of the following options is an event of the "Menu" class in ASP.NET 4.5?

Answer

Correct Answer: TrackViewState

Note: This Question is unanswered, help us to find answer for this one

29. In ASP.NET 4.5. which one of the following is not a class of the "System.Runtime.Caching" namespace?

Answer

Correct Answer: CachingSectionGroup

Note: This Question is unanswered, help us to find answer for this one

30.

Suppose, you are deploying the .NET framework redistributable package to computers on a network by using the "System Center 2012 Conf‌iguration Manager". Four steps are given below to perform the deployment process. Arrange these steps in the correct order and choose the correct answer from the following Options.

1. Creation of package and programs

2. Deployment of the package

3. Selection of distribution points

4. Creation of collection

Answer

Correct Answer:

4, 1, 3, 2  


Note: This Question is unanswered, help us to find answer for this one

31. Which of the following is NOT a class of System.Dynamic namespace?

Answer

Correct Answer: lnvokeOnGetBinder

Note: This Question is unanswered, help us to find answer for this one

32. In memory management, the managed heap is categorized into the following generations to handle long-lived and short-lived objects efficiently. Which of the given generations serves as a buffer between long-lived and short-lived objects?

Answer

Correct Answer: Generation 1

Note: This Question is unanswered, help us to find answer for this one

33. How many different chart types are provided by the "Chart" control in ASP.NET 4.5?

Answer

Correct Answer: 30

Note: This Question is unanswered, help us to find answer for this one

34. Which of the following features about culture is introduced in the dot net 4.5 framework?

Answer

Correct Answer: Culture can be set at the app domain level and will be inherited by all the threads inside that app domain level.

Note: This Question is unanswered, help us to find answer for this one

35. Which of the following statements is incorrect about .NET framework 4.5?

Answer

Correct Answer: It provides a default culture for application domain.

Note: This Question is unanswered, help us to find answer for this one

36. The classes that supports XAML in Windows Presentation Foundation are contained in which of the given namespaces?

Answer

Correct Answer: System.Windows.Xps.Serialization

Note: This Question is unanswered, help us to find answer for this one

37. Which of the following HyperLink properties is inherited from the WebControl class?

Answer

Correct Answer: Parent

Note: This Question is unanswered, help us to find answer for this one

38. Using which of the following options, you choose the platforms (such as Windows Phone and .NET for Windows Store apps) to target.

Answer

Correct Answer: Portable Class Library

Note: This Question is unanswered, help us to find answer for this one

39. The process to add the real-time web functionality to an application is simplified by the library in the dot net 4.5 framework.

Answer

Correct Answer: SignalR

Note: This Question is unanswered, help us to find answer for this one

40. Which of the following properties of the HttpReSponseBase class is used to set the value of an HTTP Location header?

Answer

Correct Answer: RedirectLocation

Note: This Question is unanswered, help us to find answer for this one

41. Which of the following lines of code is the correct manner of getting the ID of a label through the RowDataBound event of the GridView control, if the label is contained inside the GridView control?

Answer

Correct Answer: Label Label1 = (Label)e.Rows.FindControl(

Note: This Question is unanswered, help us to find answer for this one

42.

Which of the following statements is/are correct?

1. Notif‌ications are not raised by the background garbage collections if the configuration element <gcConcurrent> is enabled.

2. Notifications are not raised by the background garbage collections if the configuration element <gcConcurrent> is disabled.


Answer

Correct Answer:

Only Statement1 is correct. 


Note: This Question is unanswered, help us to find answer for this one

43. In ASP.NET 4.5, which of the following options is not a namespace?

Answer

Correct Answer: System.Configuration.DefaultSection

Note: This Question is unanswered, help us to find answer for this one

44.

Fill in the blank:

The classes that are required to create and work with activities in — are contained in the "System.Activities" namespaces.

Answer

Correct Answer:

Windows Communication Foundation


Note: This Question is unanswered, help us to find answer for this one

45. Which of the following Options is not a method of the "System.Web.HttpResponseBase" class?

Answer

Correct Answer: MembenNiseCIone

Note: This Question is unanswered, help us to find answer for this one

46. Which of the following methods of the MulticastDelegate class returns a static method represented by the current MulticastDelegate?

Answer

Correct Answer: GetMethodlmpl

Note: This Question is unanswered, help us to find answer for this one

47. Which property of the "DrOpDownList" control in ASP.NET 4.5 is used to bind the custom list items with data source?

Answer

Correct Answer: BindingContainer

Note: This Question is unanswered, help us to find answer for this one

48. Which of the following events of an ASP.NET application file is raised when the information about a particular session from the session collection is about to be serialized?

Answer

Correct Answer: Application_ReleaseRequestStateO

Note: This Question is unanswered, help us to find answer for this one

49. In ASP.NET 4.5, which of the following binding expressions is used to encode the data automatically into HTML?

Answer

Correct Answer: <#: %>

Note: This Question is unanswered, help us to find answer for this one

50. With which of the following Integrated Development Environments was the dot net 4.5 framework introduced?

Answer

Correct Answer: Visual Studio 2013

Note: This Question is unanswered, help us to find answer for this one

51. Which of the following properties does not exist in the login control of asp.net 4.5?

Answer

Correct Answer: None of the above exists

Note: This Question is unanswered, help us to find answer for this one

52. Which of the given methods of Bundle class is responsible to specify a set of files that are to be included in the Bundle?

Answer

Correct Answer: Include

Note: This Question is unanswered, help us to find answer for this one

53. In ASP.NET 4.5. which of the following controls do not have the "CommandName" and "CommandArgument" properties?

Answer

Correct Answer: LinkButton

Note: This Question is unanswered, help us to find answer for this one

54. The Windows Desktop Speech technology-types, to implement speech recognition, are contained in the namespace.

Answer

Correct Answer: System.Speech.Recognition

Note: This Question is unanswered, help us to find answer for this one

55. Which of the following namespaces def‌ines classes that are used to control the access to operations and resources based on policy?

Answer

Correct Answer: System.Security.Permissions

Note: This Question is unanswered, help us to find answer for this one

56. ln asp.net 4.5, the methods CreateFromDirectory() & ExtractToDirectory() comes under which namespace?

Answer

Correct Answer: System.|O.Compression

Note: This Question is unanswered, help us to find answer for this one

57. How you will generate a report with minimum network traffic?

Answer

Correct Answer: Use Microsoft SQL Server stored procedures for the data calculations

Note: This Question is unanswered, help us to find answer for this one

58. if you don"t specify a value for the timeout attribute in the element in web.config, for how long will the authentication cookie be valid?

Answer

Correct Answer: 30 minutes

Note: This Question is unanswered, help us to find answer for this one

59.

You are using Visual Basic to retrieve class information from a Microsoft SQL Server database named ClassList. The database Resides on a server named Neptune. Which code fragment will create a connection to this data source?

Answer

Correct Answer:

Set conn = New connection ;With conn : .Provider = 'SqIOleDB' : ConnectionStrIng ='User ID=sa;‘&& 'Data Source=Neptune;'&& 'initial Catalog=CiassList'


Note: This Question is unanswered, help us to find answer for this one

60. You have to update some values in the database. Which of the following methods would you execute on a command object named "cmdupdate?’

Answer

Correct Answer: cmd.Execute$calar0

Note: This Question is unanswered, help us to find answer for this one

61. Which of the following types of cursors is available with ADO.NET DataReader object?

Answer

Correct Answer: server-side, forward-only, and read-only cursor

Note: This Question is unanswered, help us to find answer for this one

62. Which of the following authorization and authentication methods is not provided by ASP.NET?

Answer

Correct Answer: IIS authentication

Note: This Question is unanswered, help us to find answer for this one

63.

You are creating an ASP.NET application that is hosted on your company’s Web server. You want to access a database with minimal effort. What you will not do?

Answer

Correct Answer:

Close the database connection


Note: This Question is unanswered, help us to find answer for this one

64. What is an Object in Object Oriented Programming?

Answer

Correct Answer: An entity having state and behavior

Note: This Question is unanswered, help us to find answer for this one

65.

Is the following statement true or false?

SHA1 and MD5 are the two encryption methods supported by ASP.NET.

Answer

Correct Answer:

True 


Note: This Question is unanswered, help us to find answer for this one

66. Which of the following methods is ideally suited for retrieving a single row and single column from the database?

Answer

Correct Answer: By using f‌ill method of the data adapter
All of the above

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

67.

You are creating an ASRNET application that will record each customer’s entry. It is possible that thousands of entries could be posted at any given time. Your application will be hosted on twenty Web servers. As customers enter information into your application, maintaining state information will be important This information should be stored securely and should be capable of being restored in the event that a Web server is restarted. Customers will enter data into three separate pages in your application. Which of the following methods of storing state information would best suit the situation?

Answer

Correct Answer:

SOL Server


Note: This Question is unanswered, help us to find answer for this one

68.

You are implementing the TextChanged event handler. Which two courses of action should you take? (Each correct answer presents part of the solution. Choose two)

Answer

Correct Answer:

In the Page directive for PersonaIDetaiIs.aspx. ensure that the EnableViewState attribute is set to


In the MemberID HTML element, ensure that the AutoPostback attribute is set to ‘true

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

69.

Consider the following two statements about Windows authentication and choose the most appropriate option:

1. An asterisk(’) means all users, roles or verbs, depending upon the attribute it is used in

2. A question mark(?) means ”anonymous access"

Answer

Correct Answer:

Both 1 and 2 are true 


Note: This Question is unanswered, help us to find answer for this one

70. Which of the following are false for events?

Answer

Correct Answer: All of the above are true

Note: This Question is unanswered, help us to find answer for this one

71.

Consider the following two statements and choose the most appropriate option:

1. For configuration, ASP.NET uses IIS Metabase

2. For configuration, ASP.NET uses an XML based conf‌iguration system

Answer

Correct Answer:

 2 only


Note: This Question is unanswered, help us to find answer for this one

72. The page processing stages are:

Answer

Correct Answer: Configuration. Event Handling, Rendering and Cleanup

Note: This Question is unanswered, help us to find answer for this one

73.

Consider the following two statements and choose the most appropriate option:

Statement 1: Value types are allocated on a stack

Statement 2: Reference types are allocated on a managed CLR Heap


Answer

Correct Answer:

Both statements 1 and 2 are true  


Note: This Question is unanswered, help us to find answer for this one

74. Which of the following is not a valid ASP.NET Web form control?

Answer

Correct Answer:

<ASP:Div>


Note: This Question is unanswered, help us to find answer for this one

75.

You create an ASP.NET application for ABC Corporation. The project manager requires a standard appearance for all Web applications. Standards are expected to change periodically. You need to enforce these standards and reduce maintenance time. What would you do?

Answer

Correct Answer:

Create a cascading style sheet 


Note: This Question is unanswered, help us to find answer for this one

76.

In Windows built-in authentication. what will happen with the following set of statements?

<system.web>

<authorl2atlon>

<deny users="RlL“i">

<a|low users="R|L"/"=-

<fauthorization>


<lsystem.web>

Answer

Correct Answer:

The user RlL ls denied access because the element takes precedence over the element  


Note: This Question is unanswered, help us to find answer for this one

77.

is the following statement true or false?

With the use of delegates, you can pass a method as a parameter in another method.


Answer

Correct Answer:

True 


Note: This Question is unanswered, help us to find answer for this one

78. On which of the following platforms does output caching work when using ASP.NET?

Answer

Correct Answer: Windows 2000

Note: This Question is unanswered, help us to find answer for this one

79. In Forms-based authentication. which of the following is not an attribute of the element?

Answer

Correct Answer: Machinekey

Note: This Question is unanswered, help us to find answer for this one

80. Which of the following will be returned when this command is executed using ExecuteReader method?

Answer

Correct Answer: DataReader

Note: This Question is unanswered, help us to find answer for this one

81.

XYZ is creating an e-commerce site for PremiumBouthue. The site Is distributed across multiple servers In a Web form. Users will be able to navigate through the pages of the site and select products for purchase. XYZ wants to use a DataSet object to save their selections. Users will be able to view their selections at any tinte by clicking a Shopping Cart link. XYZ wants to ensure that each user"s shopping cart DataSet object is saved between requests when the user Is making purchases on the site. How can this requirement be implement?


Answer

Correct Answer:

Use the HttpSessionState object returned by the Session property of the page to store the DataSet object- Use the Web.config file to configure an cut-of-process session route 



Note: This Question is unanswered, help us to find answer for this one

82.

Which of the two statements is true?

(a)MSIL code is platform independent

(b)CLR is platform dependent

Answer

Correct Answer:

Both (a) and (b) are true  


Note: This Question is unanswered, help us to find answer for this one

83. Which of the following languages are not part of CLR?

Answer

Correct Answer: VisualC++.Net

Note: This Question is unanswered, help us to find answer for this one

84.

You want to access data from the "Customer" table in the database. You generate a DataSet named ”MyDataSet" by adding "Customer" table to it. Which of the following statements should you use to load the data from the database into "MyDataSet" using a SqlDataAdapter named "tvlyAdapter"?

Answer

Correct Answer:

MyAdapter.Flll(MyDataSet)


Note: This Question is unanswered, help us to find answer for this one

85.

You are a web developer for an international literary website. Your application has a lot of text content that requires translation and few executable components. Which approach would you use?

Answer

Correct Answer:

Detect and redirect


Note: This Question is unanswered, help us to find answer for this one

86. The .NET framework comes with a few CLR hosts. Which of the following is a CLR host?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

87. Which of the following statements is incorrect with regard to a CommandBuilder object?

Answer

Correct Answer: it creates efficient queries In terms of performance

Note: This Question is unanswered, help us to find answer for this one

88. What does Managed Data refer to?

Answer

Correct Answer: The data allocated and de-allocated by CLR GC

Note: This Question is unanswered, help us to find answer for this one

89. Which of the following is the way to handle Unmanaged Code Exceptions in ASP.NET?

Answer

Correct Answer: Server.GetLastError()

Note: This Question is unanswered, help us to find answer for this one

90. Can you define your own Exception classes in ASP.NET?

Answer

Correct Answer: Yes

Note: This Question is unanswered, help us to find answer for this one

91.

We are iterating through the results received in a data reader named "DReaderOrder." which is created by using the connection "SqlCon." In between we need to retrieve some more values from the database. so we executed another command in the same connection to get the results in a new data reader named "ReaderProduct." What will be the result if we are using ADO.N ET 2.0?

Answer

Correct Answer:

Both will keep on reading records independent of each other


Note: This Question is unanswered, help us to find answer for this one

92. in .NET, the exception handling should be used:

Answer

Correct Answer: to signal the occurrence of unusual or unanticipated program events

Note: This Question is unanswered, help us to find answer for this one

93.

You are creating an ASP.NET application that will authenticate truck drivers for drug tests. You want to prompt users for their user names and passwords. Which type of authentication should you use in your application?

Answer

Correct Answer:

Finally block is executed after Try block when no error occurs 


Note: This Question is unanswered, help us to find answer for this one

94.

When users edit data, this code runs to completion, but no data changes appear In the database. You test the update query and the connection string that you are passing to the procedure. and they both work correctly. You need to change the code to ensure that data changes appear in the database. What should you do?

Answer

Correct Answer:

Delete this line of code:

dataTableAcceptChanges() 


Note: This Question is unanswered, help us to find answer for this one

95.

You are creating an ASP.NET application that will run on your company"s intranet. You want to control the browser window and respond immediately to non-post~back events. Which should you use?

Answer

Correct Answer:

Client-side scripts


Note: This Question is unanswered, help us to find answer for this one

96.

You create an ASP.NET page that allows a user to enter a requested delivery date in a TextBox control named txtDelDate. The date must be no earlier than two business days after the order date. and no later that 60 busmess days after the order date. You add a CustomValidator control to your page. In the Properties window you set the ControIToValidate property to txtDeiDate. You need to ensure that the date entered in the txtDelDate TextBox control falls within the acceptable range of values. In addition. you need to minimize the number of round trips to the server. What should you do?

Answer

Correct Answer:

Set the AutoPostBack property of txtDelDate to False. Set the ClientValidatlonFunction property to the name of a script function contained in the HTML page that is sent to the browser.


Note: This Question is unanswered, help us to find answer for this one

97.

Which of the following are true Serializable objects (ie. they implement Serializable interface)?

Answer

Correct Answer:

DataSet and DataTable


Note: This Question is unanswered, help us to find answer for this one

98.

You are debugging an ASP.NET application for Premium Corp.. Users will use the application to produce reports. Your application contains several DebquriteLine statements. Which window in Visual Studio .NET should you use to inspect output from the Debug.WriteLine statements?

Answer

Correct Answer:

Output 


Note: This Question is unanswered, help us to find answer for this one

99. Dot Net Framework consists of :

Answer

Correct Answer: Common language runtime and set of class libraries

Note: This Question is unanswered, help us to find answer for this one

100.

What does the following line of code do?

<%@ Register tagprefix="ril" Tagname="test" Src="rilTest.ascx" %>


Answer

Correct Answer:

Register a new user control


Note: This Question is unanswered, help us to find answer for this one

101. How many times can classes be nested within a class?

Answer

Correct Answer: Any number of times

Note: This Question is unanswered, help us to find answer for this one

102. What is the total no. of events in Global.asax f‌ile in Asp.NET?

Answer

Correct Answer: 19

Note: This Question is unanswered, help us to find answer for this one

103.

You are the software engineer for Premium Corp.. One of the pages in an ASP.NET application contains the following declaration:

<%@ Register Tagpref‌ix="WoodySideBankControls" Namespace="WoodySideBankNameSpace" Assembly=”MyAssembiy" $63-

The assembly named MyAssembly contains a custom server control named CSC1. Which of the following code samples will

property render CSCi on the Web page?


Answer

Correct Answer: <Woody$ideBankControls:CSC1 id=‘Control1' runat='server' />


Note: This Question is unanswered, help us to find answer for this one

104. Which of the following is not a valid directive?

Answer

Correct Answer: @lnsert

Note: This Question is unanswered, help us to find answer for this one

105. Which of the following is not a service provided by Common Language Runtime (CLR)?

Answer

Correct Answer: Multiple platform support

Note: This Question is unanswered, help us to find answer for this one

106. Dot NET Framework programs are compiled into CPU independent instruction set. named:

Answer

Correct Answer: Microsoft intermediate Language

Note: This Question is unanswered, help us to find answer for this one

107.

John is maintaining an ASP.NET application named HigherProfits. The application is written In Visual Basic .NET. The application includes a page named YearlySale.aspx that resides within the Sales namespace. The page class is named Yearlysale. You discover that another developer accidentally deleted the Page directive for YearlySale.aspx. You want to create a new Page directive to allow YearlySaieaspx to work properly. Which directive should you use?

Answer

Correct Answer:

<%@ Page Language=‘vb' Codebehind='YearinaIe.aspx.vb' Innerits=‘SaIes.Yearinale‘%>


Note: This Question is unanswered, help us to find answer for this one

108.

You are debugging a Visual Basic application. You add a variable to the watch window. When Visual Basic enters break mode, the Value of the expression variable is ". What is the most likely cause of the problem?

Answer

Correct Answer:

The variable has been def‌ined as public.


Note: This Question is unanswered, help us to find answer for this one

109. Which of the following is not a feature of .NET 2.0?

Answer

Correct Answer: multiple lnheritance

Note: This Question is unanswered, help us to find answer for this one

110. Which DLL is responsible for processing the page requests running on the server?

Answer

Correct Answer: internet Server Application Programming interface

Note: This Question is unanswered, help us to find answer for this one

111.

Two users, Monique and James are using ADO.NET MlS system. The data refresh time In the system is set to 15 minutes. James changed the mailing address of a customer named Majda, and updated the database. Before database refresh. Monique also updated the same customer"s address as per her pending requests folder. What will happen when Monique saves the changes?

Answer

Correct Answer:

DBConcurrencyException will be thrown  


Note: This Question is unanswered, help us to find answer for this one

112. In which of the following namespaces is the Assembly class defined?

Answer

Correct Answer: System.Reflection

Note: This Question is unanswered, help us to find answer for this one

113.

You are creating an ASP.net application to enter timesheet data intuitively. Users will enter data using a data grid. You have added a button column to your data grid. The button column uses a custom button to allow users to initiate some calculations on the data in the grid. Which event does the DataGrid control raise when the custom button is clicked?


Answer

Correct Answer:

ltemCommand 


Note: This Question is unanswered, help us to find answer for this one

114.

You want to create a cookie object named “CustomerAddress" of type "Ctlstomerlnfo" to maintain address information of customers who buy products online. Which of the following code snippets should you use to create this cookie?

Answer

Correct Answer:

 Dim CustomerAddress As New HttpCookier('Customerinfo') 


Note: This Question is unanswered, help us to find answer for this one

115. Which of the following is not an event of the Page class?

Answer

Correct Answer: Abort

Note: This Question is unanswered, help us to find answer for this one

116. What will happen if the Server configuration file and the Application configuration file have different values for session state?

Answer

Correct Answer: The Server configuration will override the Application conf‌iguration if allowOverride is set to ‘false' in the settings in the Server configuration file

Note: This Question is unanswered, help us to find answer for this one

117. Which of the following is the default configuration f‌ile for each application?

Answer

Correct Answer: web.conf‌lg

Note: This Question is unanswered, help us to find answer for this one

118. Which of the following will set the default language for all of your application logic to C#?

Answer

Correct Answer: <compilation debug='false' expliclt='true' defaultLanguage=’C#'>

Note: This Question is unanswered, help us to find answer for this one

119. Which of the following code is not "managed" by default in .NET framework?

Answer

Correct Answer: C++

Note: This Question is unanswered, help us to find answer for this one

120. Which of the following is a benefit derived from using OOPS?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

121. Which of the following can be used to add an Unbound Column in a DataGrid?

Answer

Correct Answer: ASP:TempateColumn
ltemTemplate

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

122.

You created a stored procedure to retrieve the following details for the given customer:

CustomerName, Address, PhoneNumber

Which of the following is an ideal choice to get the best performance?


Answer

Correct Answer:

Return the result as three out parameters and command object 


Note: This Question is unanswered, help us to find answer for this one

123.

You are creating an ASP.NET page for Premium Consultants. You create a DataGrid control that displays past purchases made by the user. The DataGrid control is populated from an existing database when the page is created. The page contains TextBox controls that allow users to update their personal information, such as address and telephone number. You need to ensure that the page is refreshed as quickly as possible when users update their contact information.

What should you do?

Answer

Correct Answer:

Write code in the Page.Load event handler that populates the DataGrid control only when the isPostBack  


Note: This Question is unanswered, help us to find answer for this one

124. Control"s value set during the postback can be accessed in:

Answer

Correct Answer: Page_Load

Note: This Question is unanswered, help us to find answer for this one

125.

You are developing a website that has four layers. The layers are user interface (web pages). businessobjects. data objects, and database. You want to pass data from the database to controls on a web form. What should you do?

Answer

Correct Answer:

Populate the data objects with data from the database. Populate the business objects with data from the data objects. Populate the controls with values retrieved from the business objects


Note: This Question is unanswered, help us to find answer for this one

126. Which of the following are not true?

Answer

Correct Answer: You can use goto within the finally block in Order to jump out of the finally Block

Note: This Question is unanswered, help us to find answer for this one

127. In CLR, is it possible to create a class in C# that inherits from a VB class?

Answer

Correct Answer: Yes

Note: This Question is unanswered, help us to find answer for this one

128. What happens when boxing occurs?

Answer

Correct Answer: The contents of a value type are copied from the stack into the memory allocated on the managed heap

Note: This Question is unanswered, help us to find answer for this one

129.

You have developed a custom server control and have compiled it into a f‌ile named FirstReportdll. The code is displayed below:


<%@ Register TagPref‌ix=” CertKing Tag" Namespace="ReportNS" Assembly=" CertKing Report" %>

You want to set the PageNumber property of the control to 77.


Which of the following lines of code should you include In your Web Form?

Answer

Correct Answer:

< CertKlng Tag:myReport PageNumber='77' runat='server' />


Note: This Question is unanswered, help us to find answer for this one

130. Which of the following help increase the code clarity?

Answer

Correct Answer: Abstraction
Encapsulation

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

131. Server based controls can be accessed from:

Answer

Correct Answer: Server code only

Note: This Question is unanswered, help us to find answer for this one

132. Which helped overcome the DLL conflict (faced by the versions prior to .NET).

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

133. when is the viewstate created?

Answer

Correct Answer: After Page lnit event

Note: This Question is unanswered, help us to find answer for this one

134. When you make some changes to the configuration file. do you need to stop and start IIS to apply the new settings?

Answer

Correct Answer: No

Note: This Question is unanswered, help us to find answer for this one

135. Which of the following does not constitute the benef‌its of CLR?

Answer

Correct Answer: lDL (Interface Definition Language) use is promoted by restricting self describing objects

Note: This Question is unanswered, help us to find answer for this one

136.

You are creating an ASP.NET application for AutoMart Internet Web site. A toolbar is required that will be displayed at the top of each page in the Web site. The toolbar will contain only static HTML code. The toolbar will be used in only AutoMart website. You plan to create the toolbar as a reusable component for your application. You need to create the toolbar in am possible time. Which method will you adopt?

Answer

Correct Answer:

Add a new Web user control to your ASP.NET project. Create the toolbar within the Web user Control. 



Note: This Question is unanswered, help us to find answer for this one

137.

You are creating an ASP.NET page for your company"s Web site. Customers will use the ASP.NET page to enter payment information. You add a DropDownList control named oPaymentTypeList that enables customers to select a type of credit card and bank accounts. You need to ensure that customers select a credit card type. You want a default value of Select to be displayed in the oPaymentTypeList control. You want the page validation to fail if a customer does not select a payment type from the list. What should you do?

Answer

Correct Answer:

Add a RequiredFieldValidator control and set its ControlToValidate property to oPaymentTypeList. Set the lnitialdValue property of the RequiredFleldVaildator control to Select.


Note: This Question is unanswered, help us to find answer for this one

138.

You create an ASP.NET page named Customecaspx. Customeizaspx contains a Web user control that displays a drop—down list box of Cities. The Web user control is named CityList, and it is def‌ined in a f‌ile named CityList.ascx. The name of the DropDownList control in Cityascx is CuCity. You try to add code to the Page.Load event handler for Customenaspx. but you discover that you cannot access CuCity from code in Customeraspx. You want to ensure that code within Customeraspx can access properties of CuCity.

What should you do?

Answer

Correct Answer:

 in the code-behind f‌ile for CityListascx. add the following line of code:

Public CuCity As DropDownList



Note: This Question is unanswered, help us to find answer for this one

139.

You have defined a command named "comA" and an open connection named "con". You created a new transaction:

Dim trans As SglClienthlTransaction — Nothing

How will you assign the command to the transaction and begin the transaction?

Answer

Correct Answer:

 trans = con.BeginTransaction()

cmdATransaction = trans

cmdAExecuteNonQuery()



Note: This Question is unanswered, help us to find answer for this one

140. How many bits does the int datatype use in .NET?

Answer

Correct Answer: 32 bits

Note: This Question is unanswered, help us to find answer for this one

141. Which of the following are the valid methods of the SqlTransaction class?

Answer

Correct Answer: Commit
Save
Rollback

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

142.

is the following statement true or false?

There can only be one @control directive in a single f‌ile.


Answer

Correct Answer:

True 


Note: This Question is unanswered, help us to find answer for this one

143. .NET framework has data providers for:

Answer

Correct Answer: Oracle. OleDb. Sql Server. and 0DBC

Note: This Question is unanswered, help us to find answer for this one

144.

You create an ASP.NET page named ProjectCalendar.aspx that shows scheduling information for projects in your company. The page is accessed from various other ASP and ASP.NET pages hosted throughout the company’s intranet. All employees on the intranet use Internet Explorer. ProjectCalertdar.aspx has a Calendar control at the top of the page. Listed below the Calendar control is detailed information about project schedules on the data selected. When a user selects a date in the calendar. The page is refreshed to show the project schedule details for the newly selected date. Users report that after viewing two or more dates on ProjectCalendar.aspx. they need to click the browser's Back button several times in order to return to the page they were viewing prior to accessing ProjectCalendaraspx.

You need to modify ProjectCalentlaraspx so that the users need to click the Back button only once. What to do?

Answer

Correct Answer:

Add the following attribute to the Page directive for ProjectCalertdar.aspx: StartNavigation=‘True'  



Note: This Question is unanswered, help us to find answer for this one

145.

You are creating an ASP.NET application. Tire application will be deployed on intranet. Application uses Microsoft Windows authentication. More than 100 users will use the ASP.NET application simultaneously. The project manager wants you to use connection pooling. What should you do?

Note: This Question is unanswered, help us to find answer for this one

146. What is Encapsulation?

Answer

Correct Answer: Wrapping functions and data into a single unit

Note: This Question is unanswered, help us to find answer for this one

147. How can you view the results of Trace.Write() statements?

Answer

Correct Answer: By enabling page tracing
By enabling application tracing

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

148.

You are developing an application to take orders over the lnternet. When the user posts back the order form, you f‌irst check to see whether he is a registered customer of your company. if not, you must transfer control to the Register html page. Which method should you use to effect this transfer?

Answer

Correct Answer:

Response.Redirect() 


Note: This Question is unanswered, help us to find answer for this one

149. How can you pop-up a window to display text that identifies the author of the book?

Answer

Correct Answer: In the onmouseover event handler for each image, add code that calls the RaiseBubbleEventO method of the System.Web.Ul.WebControl.image class

Note: This Question is unanswered, help us to find answer for this one

150.

Your company, Storeit inc has stored the text of several journals in a Microsoft SOL Server 7.0 database. Each sentence is stored in a separate record so that the text can be retrieved with the finest granularity. Several of these works are many thousands of printed pages in length. You are building a Web application that will allow registered users to retrieve data from these volumes. When a user of your Web application requests large amounts of text. your application must return it in the most eff‌icient manner possible. How should you build the large String object that is required to provide the most eff‌icient response to the user?


Answer

Correct Answer:

Use the StringBuilder class.


Note: This Question is unanswered, help us to find answer for this one

151. Which of the following is capable of returning multiple rows and multiple columns from the database?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

152. Which of the following directives can be used to include libraries in an ASP.NET page?

Answer

Correct Answer: import

Note: This Question is unanswered, help us to find answer for this one

153.

You need to install an online parcel tracking application and its supporting assemblies so that the application and its assemblies can be uninstalled using the Add/remove Programs Control Panel applet. What should you do?

Answer

Correct Answer:

Use a Web installation package to install the Web application and the supporting assemblies


Note: This Question is unanswered, help us to find answer for this one

154. The global assembly cache:

Answer

Correct Answer: Can store two dll f‌iles with the same name, but different version

Note: This Question is unanswered, help us to find answer for this one

155. You have three classes named A, B, and C. The class B is derived from class A and class C is derived from B. Which of the following relations are correct for the given classes?

Answer

Correct Answer: B is a A
C is a B

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

156. Which of the following classes acts as a base class when you develop your own custom control?

Answer

Correct Answer: Control

Note: This Question is unanswered, help us to find answer for this one

157. How many classes can a single .NET DLL contain?

Answer

Correct Answer: Unlimited

Note: This Question is unanswered, help us to find answer for this one

158. What are the core components of .Net framework data provider model?

Answer

Correct Answer: DataAdapter . DataReader. Connection. and Command

Note: This Question is unanswered, help us to find answer for this one

159. The XML web services of .NET framework are built on:

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

160. in .NET framework. what are the options available for packaging?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

161. Which of following is correct If you want to import a Cr: class called myClass that is implemented in the myClass.cs file into a .aspx page?

Answer

Correct Answer: <%@Page Inherits-'myCIass' Src-‘myClass.cs' %>

Note: This Question is unanswered, help us to find answer for this one

162. Which of the following is correct when starting a form tag?

Answer

Correct Answer: <form runat='server>

Note: This Question is unanswered, help us to find answer for this one

163. Inheritance is a process by which the objects of parent class acquire the properties of child class.

Answer

Correct Answer: True

Note: This Question is unanswered, help us to find answer for this one

164. Which of the following is not an ASP.NET Input Validation Control?

Answer

Correct Answer:

Note: This Question is unanswered, help us to find answer for this one

165.

You are creating an ASP.NET Website for your company. The Website will use both MicrosoftR) .NET Framework server controls and ActiveX controls. You want to use Microsoft Visual Studio(R) .NET to create a Setup and Deployment project to package the Activex controls. Which project type should you create?

Answer

Correct Answer:

Web Setup


Note: This Question is unanswered, help us to find answer for this one

166. Which line of code should you use to copy the edited rows from dataset Licenselnfo into another dataset LicenseChanges?

Answer

Correct Answer: productChanges = productlnfo.GetChanges()

Note: This Question is unanswered, help us to find answer for this one

167. Which of the following objects is required by the Dataset to retrieve data from a database and to save updated data back to the database?

Answer

Correct Answer: DataAdapter

Note: This Question is unanswered, help us to find answer for this one

168. Which of the following options is ideally suited for managing database connections?

Answer

Correct Answer: Close the connection as soon as database operation is done

Note: This Question is unanswered, help us to find answer for this one

169. Which of the following is true about AutoPostBack property of a server control?

Answer

Correct Answer: Both are true.

Note: This Question is unanswered, help us to find answer for this one

170.

Declaring more than one page directives on an ASP.NET page will result in?

Answer

Correct Answer: A compile-time error

Note: This Question is unanswered, help us to find answer for this one

171.

____is the namespace within the Microsoft.NET framework which provides the functionality to implement transaction processing.

Answer

Correct Answer: System.EnterpriseServices

Note: This Question is unanswered, help us to find answer for this one

172.

Which property below affects how the .NET Framework handles formatting issues, sorting issues, currencies and handling dates?

Answer

Correct Answer: CurrentCulture

Note: This Question is unanswered, help us to find answer for this one

173.

Which option retrieves the dynamically created template container object and is used for adding child controls programmatically?

Answer

Correct Answer: ContentTemplateContainer

Note: This Question is unanswered, help us to find answer for this one

174.

Which option below uses multi-language abilities and allows Web pages to be coded in VB.NET, C#, J# and Delphi.NET?

Answer

Correct Answer: Language Runtime

Note: This Question is unanswered, help us to find answer for this one

175.

Which of the following is true about Connecting SqlAzure database in conventional way?

Answer

Correct Answer: Yes, to connect to SQL Azure you just need the right connection string (and to set the SQL Azure firewall to allow connections from your IP address).
You won't be able to install the Windows Azure SDK without Windows Vista, Windows 7, or Windows Server 2008, but you don't need Windows Azure to use SQL Azure.

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

176.

If there are threads in a .NET Framework, which option will tell you the priority level for the threads?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

177.

Which option defines the collection trigger objects with each corresponding to an event the causes the panel to refresh automatically?

Answer

Correct Answer: Triggers

Note: This Question is unanswered, help us to find answer for this one

178.

To enable client-side callbacks in an ASP.NET page that do not trigger a postback, you must need to?

Answer

Correct Answer: Implement ICallbackEventHandler interface on that page

Note: This Question is unanswered, help us to find answer for this one

179.

How can you use real-time configurations in an ASP.NET application without restarting it?

Answer

Correct Answer: ExeConfigurationFileMap exConfigFile = new ExeConfigurationFileMap(); exConfigFile.ExeConfigFilename = Server.MapPath("app.config"); Configuration config = ConfigurationManager.OpenMappedExeConfiguration(exConfigFile, ConfigurationUserLevel.None); string testConfig = config.AppSettings.Settings["Test"].Value;

Note: This Question is unanswered, help us to find answer for this one

180.

Which statement is True?

Answer

Correct Answer: Custom controls are displayed correctly in VS.Net Designer.

Note: This Question is unanswered, help us to find answer for this one

181.

Which option will allow you to get the text inside the new HTMLEditor in ASP.Net Ajax Control Toolkit?

Answer

Correct Answer: controlName.Content

Note: This Question is unanswered, help us to find answer for this one

182.

_____ is a property of the session object that is used to set the local identifier.

Answer

Correct Answer: LCID

Note: This Question is unanswered, help us to find answer for this one

183.

Where can we assign value to Static read only member variable of a static class?

Answer

Correct Answer: Default constructor

Note: This Question is unanswered, help us to find answer for this one

184.

Accessing Asp.net controls using jQuery is demonstrated by

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

185.

You are developing an ASP.NET MVC 2 application. A view contains a form that allows users to submit their first name. You need to display the value that is submitted, and you must ensure that your code avoids crosssite scripting. Which code segment should you use?

Answer

Correct Answer: B. <%: Model.FirstName %>

Note: This Question is unanswered, help us to find answer for this one

186.

If one has two different web form controls in an application and if one wanted to know whether the values in the two different web form controls match, what control must be used?

Answer

Correct Answer: CompareValidator

Note: This Question is unanswered, help us to find answer for this one

187.

The following control option will be used when you have 2 different web form controls in an application and you want to know whether the values in the 2 different web form control match:

Answer

Correct Answer: CompareValidator

Note: This Question is unanswered, help us to find answer for this one

188.

ASP.NET Page class has IsPostBack property. How does ASP.NET recognize a Postback?

Answer

Correct Answer: Postback information is stored in HttpRequest object
Postback information is stored in HttpRequest object

Note: This question has more than 1 correct answers

Note: This Question is unanswered, help us to find answer for this one

189.

Code behind classes are partial classes because?

Answer

Correct Answer: There can be multiple code-behind classes for an .ASPX file

Note: This Question is unanswered, help us to find answer for this one

190.

____ is not a member of ADODBCommand object?

Answer

Correct Answer: Open

Note: This Question is unanswered, help us to find answer for this one

191.

How can you determine what version(s) of ASP.NET are running on a system?

Answer

Correct Answer: Response.Write(System.Environment.Version.ToString() );

Note: This Question is unanswered, help us to find answer for this one

192.

The difference between ListView and GridView is?

Answer

Correct Answer: ListView does not generate Html table by default, but GridView does

Note: This Question is unanswered, help us to find answer for this one

193.

We should install an SSL certificate on an IIS website so that?

Answer

Correct Answer: All the traffic to and from IIS is encrypted

Note: This Question is unanswered, help us to find answer for this one

194.

How do you ensure that a TextBox input is a valid Date value?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

195.

What is the default file upload size supported by ASP.NET in mega bytes?

Answer

Correct Answer: 4MB

Note: This Question is unanswered, help us to find answer for this one

196.

If a server control is declared inside an UpdatePanelUpdateMode="Conditional",Which of the following statements is true?

Answer

Correct Answer: UpdatePanel.Update() method must be called to show any changes in the server control

Note: This Question is unanswered, help us to find answer for this one

197.

The maximum number of content placeholders in a master page is?

Answer

Correct Answer: Unlimited

Note: This Question is unanswered, help us to find answer for this one

198.

The purpose of Page.EnableEventValidation="true" is that?

Answer

Correct Answer: It validates that a control event originated from the user interface that was rendered by that control

Note: This Question is unanswered, help us to find answer for this one

199.

Let's suppose a SqlDataSource and a GridView are configured with SELECT and UPDATE queries; and GridView has AutoGenerateEditButton=True, how can we ensure data concurrency in an efficient way?

Answer

Correct Answer: Add a ConflictDetection attribute to SqlDataSource

Note: This Question is unanswered, help us to find answer for this one

200.

Which of the following is not a column type for a GridView?

Answer

Correct Answer: CustomField

Note: This Question is unanswered, help us to find answer for this one

201.

Which of the following is not a valid option in OutputCache directive?

Answer

Correct Answer: VaryByUserAgent

Note: This Question is unanswered, help us to find answer for this one

202.

Which of the following session-state modes is not a valid option for the Web Farm deployment to work?

Answer

Correct Answer: InProc

Note: This Question is unanswered, help us to find answer for this one

203.

What is middleware in ASP.NET Core/Open Web Interface for .NET (OWIN)?

Answer

Correct Answer: Software components that are assembled into an application pipeline to handle requests and responses

Note: This Question is unanswered, help us to find answer for this one

204.

Which of these controls can be declared inside a TemplateField of a GridView control?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

205.

Let's suppose, the web.config has defined a theme for the application, but theming is disabled in the master page file like this: <%@ Master EnableTheming="false" %> Which of the following statements will be true:

Answer

Correct Answer: Any content page can enable theme for itself by adding EnableTheming='true' attribute in its page directive

Note: This Question is unanswered, help us to find answer for this one

206.

How do you ensure that a validator control displays error message only when the associated control is invalid?

Answer

Correct Answer: Set validator's DisplayMode="Dynamic"

Note: This Question is unanswered, help us to find answer for this one

207.

ASP.NET Page Unload event is raised when?

Answer

Correct Answer: The page and its controls have been rendered

Note: This Question is unanswered, help us to find answer for this one

208.

Let's suppose, on an .ASPX page, we have two separate data entry forms with submit buttons. How can we ensure that submitting the first form does not validate any controls in the second form, and vice versa?

Answer

Correct Answer: Assign two different validation groups to both forms and their controls

Note: This Question is unanswered, help us to find answer for this one

209.

Users with which Role(s) will be able to use TestController defined below? [Authorize(Roles = "Admin")] [Authorize(Roles = "Group")] public class TestController : Controller { ... }

Answer

Correct Answer: With "Admin" AND "Group" roles

Note: This Question is unanswered, help us to find answer for this one

210.

Declaring more than one form tags with runat="server" on an ASPX page will result in?

Answer

Correct Answer: A run-time error

Note: This Question is unanswered, help us to find answer for this one

211.

Which of these tags equals Response.Write?

Answer

Correct Answer: <%= ... %>

Note: This Question is unanswered, help us to find answer for this one

212.

For an ASP.NET deployment, .NET framework is configured at which level?

Answer

Correct Answer: Individually decided for each virtual directory or application

Note: This Question is unanswered, help us to find answer for this one

213.

If runat="server" is omitted from a GridView definition, which one of the following statements will not be true?

Answer

Correct Answer: This will result in a run time error

Note: This Question is unanswered, help us to find answer for this one

214.

Accessing Asp.net controls using jQuery as following?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

215.

How can I tell the website administration tool which provider to use following code?

Answer

Correct Answer: <membership defaultProvider="DefaultMembershipProvider"><providers><add connectionStringName="DefaultConnection" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" requiresUniqueEmail="true" maxInvalidPasswordAttempts="5" minRequiredPasswordLength="6" minRequiredNonalphanumericCharacters="0" passwordAttemptWindow="10" applicationName="/" name="DefaultMembershipProvider" type="System.Web.Providers.DefaultMembershipProvider, System.Web.Providers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" /></providers></membership>

Note: This Question is unanswered, help us to find answer for this one

216.

The goal is to enable single-sign-on across multiple ASP.NET applications. Which of the following statements will be true?

Answer

Correct Answer: The machine key, forms-authentication name and path should be the same across all the applications

Note: This Question is unanswered, help us to find answer for this one

217.

The default session timeout value for an ASP.NET application or website?

Answer

Correct Answer: 20 minutes

Note: This Question is unanswered, help us to find answer for this one

218.

What are the components of the ASP.NET AJAX architecture?

Answer

Correct Answer: You can divide the ASP.NET AJAX architecture into two components - AJAX client architecture and AJAX server architecture.

Note: This Question is unanswered, help us to find answer for this one

219.

Why should you create a custom role provider?

Answer

Correct Answer: E. B and C both

Note: This Question is unanswered, help us to find answer for this one

220.

If I’m developing an application that must accommodate multiple security levels though secure login and my ASP.NET web application is spanned across three web servers (using round-robin load balancing) what would be the best approach to maintain login-in state for the users?

Answer

Correct Answer: Maintain the login state security through a database.

Note: This Question is unanswered, help us to find answer for this one

221.

What are the new features of ASP.NET AJAX 4.0?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

222.

An extension with both client-side as well as server-side components for writing ASP.NET pages that incorporate AJAX functionality?

Answer

Correct Answer: ASP.NET AJAX

Note: This Question is unanswered, help us to find answer for this one

223.

Which of the following does not have any visible interface?

Answer

Correct Answer: Repeater

Note: This Question is unanswered, help us to find answer for this one

224.

For your ASP.NET web application your graphics designer created elaborate images that show the product lines of your company. Some of graphics of the product line are rectangular, circular, and others are having complex shapes. You need to use these images as a menu on your Website. What is the best way of incorporating these images into your Website?

Answer

Correct Answer: Use an ImageMap control and define hot spot areas for each of the product lines. Use the PostBackValue to identify the product line that was clicked.

Note: This Question is unanswered, help us to find answer for this one

225.

We have defined one page_load event in aspx page and same page_load event in the code behind which of the following will run first?

Answer

Correct Answer: page_load event in code-behind

Note: This Question is unanswered, help us to find answer for this one

226.

What is/are the predefined TraceListener(s) in ASP.Net?

Answer

Correct Answer: All the above 1, 2,3

Note: This Question is unanswered, help us to find answer for this one

227.

You are modifying an ASP.NET MVC web application and you have created a new master layout page named _Layout.WindowsPhone.cshtml. You want to use that layout in a new view. Which code segment do you use?

Answer

Correct Answer: B. Layout="~/Views/Shared/_Layout.WindowsPhone.cshtml";

Note: This Question is unanswered, help us to find answer for this one

228.

__ element in the web.config file to run code using the permissions of a specific user?

Answer

Correct Answer: identity element

Note: This Question is unanswered, help us to find answer for this one

229.

In your ASP.NET 2.0 web application you want to display an image that is selected from a collection of images. What approach will you use to implementing this?

Answer

Correct Answer: Use the AdServer control and create an XML file with configuration of the control.

Note: This Question is unanswered, help us to find answer for this one

230.

If you have View with @Page directive to inherit from ViewPage then your View is_____?

Answer

Correct Answer: Strongly Typed View

Note: This Question is unanswered, help us to find answer for this one

231.

How could you traditionally consume an ASMX web service from your application?

Answer

Correct Answer: 2 and 3 both.

Note: This Question is unanswered, help us to find answer for this one

232.

In order to prevent a browser from caching a page which of these statements should be written?

Answer

Correct Answer: Response.Cache.SetNoStore();

Note: This Question is unanswered, help us to find answer for this one

233.

Layout.cshtml and Site.Master are the two default template pages in ASP.NET MVC. Which of the following scenarios would best be solved using a single layout or master template?

Answer

Correct Answer: 1 and 3 both

Note: This Question is unanswered, help us to find answer for this one

234.

Where are routes registered in ASP.NET MVC Application?

Answer

Correct Answer: Global.ascx

Note: This Question is unanswered, help us to find answer for this one

235.

As you design a session-less state management system, what do you need to ensure that your application manages?

Answer

Correct Answer: 1 and 4 both

Note: This Question is unanswered, help us to find answer for this one

236.

Which of the following is not a valid type of parameter for an SqlDataSource?

Answer

Correct Answer: LocalStorageParameter

Note: This Question is unanswered, help us to find answer for this one

237.

Custom Controls are derived from which of the following classes?

Answer

Correct Answer: System.Web.UI.Customcontrols.Webcontrol

Note: This Question is unanswered, help us to find answer for this one

238.

Which kind of data we can store in ViewState?

Answer

Correct Answer: Viewstate can store only serializable object

Note: This Question is unanswered, help us to find answer for this one

239.

Defines the collection trigger objects, each corresponding to an event causing the panel to refresh automatically.

Answer

Correct Answer: Triggers

Note: This Question is unanswered, help us to find answer for this one

240.

For an ASP.NET deployment on IIS, the maximum number of worker processes are defined at which level?

Answer

Correct Answer: At Application Pool level

Note: This Question is unanswered, help us to find answer for this one

241.

Which of the following is the way to monitor the web application?

Answer

Correct Answer: ALL

Note: This Question is unanswered, help us to find answer for this one

242.

What is the best way to intercept every request for an image on your site and ensure that a watermark is added to the image?

Answer

Correct Answer: C. A custom HTTP handler configured to serve .png and .jpg files

Note: This Question is unanswered, help us to find answer for this one

243.

ASP.NET/URL Rewriting in a development environment?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

244.

Which of the following represents the best use of the Table, TableRow, and Table-Cell controls?

Answer

Correct Answer: To create a customized control that needs to display data in a tabular fashion

Note: This Question is unanswered, help us to find answer for this one

245.

Explain the limitations of AJAX as following statement?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

246.

You are the lead developer on a team that has been working on a large website for months, and several controllers are getting unwieldy. You do not have that problem with views and models because most of your communications are through AJAX to display snippets of information on the UI. What changes can best help you solve your problem?

Answer

Correct Answer: 1 and 3 both

Note: This Question is unanswered, help us to find answer for this one

247.

What are the different controls of ASP.NET AJAX?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

248.

User configurable arbritrary list filtering in C#?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

249.

_____ is a data source control which will not implement Caching.

Answer

Correct Answer: LinqDataSource

Note: This Question is unanswered, help us to find answer for this one

250.

How ASP.Net Different from classic ASP?

Answer

Correct Answer: Scripting is separated from the HTML, Code is compiled as a DLL, the DLLs can be executed on server

Note: This Question is unanswered, help us to find answer for this one

251.

What technologies are being used in AJAX?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

252.

ASP.NET uses the multi-language abilities of the .NET Common _____ , allowing Web pages to be coded in VB.NET, C#, J#, Delphi.NET?

Answer

Correct Answer: Language Runtime

Note: This Question is unanswered, help us to find answer for this one

253.

What namespace does the Web page belong in the .NET Framework class hierarchy?

Answer

Correct Answer: System.web.UI.Page

Note: This Question is unanswered, help us to find answer for this one

254.

What data types do a Rangevalidator supports?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

255.

What is the sequence in which Page_Load events are executed?

Answer

Correct Answer: Page, Master Page, User Control

Note: This Question is unanswered, help us to find answer for this one

256.

What’s the difference between Response.Write() and Response.Output.Write()?

Answer

Correct Answer: The latter one allows you to write formatted output.

Note: This Question is unanswered, help us to find answer for this one

257.

In my .NET Framework, I have threads. Which of the following denotes the possible priority level for the threads?

Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

258.

The .NET Framework provides a runtime environment called?

Answer

Correct Answer: CLR

Note: This Question is unanswered, help us to find answer for this one

259.

Which page event is the most suitable to programmatically change the master page?

 

Answer

Correct Answer: PreInit

Note: This Question is unanswered, help us to find answer for this one

260.

An ASP.NET page uses a Datagrid displays employee information.The Web application supports a large number of concurrent users, who will be saving data from the grid back to the database. It is important that the Web application doesn't overwhelm the Web Server?

Answer

Correct Answer: Disable View State and don't use session state

Note: This Question is unanswered, help us to find answer for this one

261.

Which process runs the ASP.NET application on a web server?

Answer

Correct Answer: w3wp.exe

Note: This Question is unanswered, help us to find answer for this one

262.

The .NET framework which provides automatic memory management using a technique called __ ?

Answer

Correct Answer: Garbage Collection

Note: This Question is unanswered, help us to find answer for this one

263.

What is the lifespan for items stored in viewstate?

Answer

Correct Answer: Exists for the Life of the current page

Note: This Question is unanswered, help us to find answer for this one

264.

Which of the following languages are used to write server side scripting in ASP.NET?

Answer

Correct Answer: Both C-sharp and VB

Note: This Question is unanswered, help us to find answer for this one

265.

Which DLL translate XML to SQL in IIS?

Answer

Correct Answer: SQLISAPI.dll

Note: This Question is unanswered, help us to find answer for this one

266.

Which one of these file extensions will not be served over HTTP and any direct URL request for it is automatically rejected?

Answer

Correct Answer: .asax

Note: This Question is unanswered, help us to find answer for this one

267. Which is not a drawback of cookies?



Answer

Correct Answer: Cookies can slow down data transfer speeds<br>

Note: This Question is unanswered, help us to find answer for this one

268. You are posting values from an HTML form to an ASP page. The HTML form contains a radio button group named mstatus with the following definition:




In the ASP page, how will you determine which radio button was selected by the user?


Answer

Correct Answer: if request.form("mstatus")="single" then .....

Note: This Question is unanswered, help us to find answer for this one

269. What does the HTTP_USER_AGENT server variable represent?



Answer

Correct Answer: The browser being used by the client

Note: This Question is unanswered, help us to find answer for this one

270. Which of the following holds true regarding database handling in ASP?


Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

271. How are sessions maintained in ASP?


Answer

Correct Answer: The browser sends a cookie to the server with each request

Note: This Question is unanswered, help us to find answer for this one

272. How can you limit the number of rows returned by a database query?


Answer

Correct Answer: By using the Where clause of the Select statement

Note: This Question is unanswered, help us to find answer for this one

273. What type of data can be accessed through ActiveX Data Objects?


Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

274. Which of the following is false about the below statement?

       response.expires = 0



Answer

Correct Answer: It can only be specified if buffering for the page is enabled

Note: This Question is unanswered, help us to find answer for this one

275. After how many minutes does the ASP session expire?


Answer

Correct Answer: 20 minutes

Note: This Question is unanswered, help us to find answer for this one

276. The browser is sending an HTTP header with the name Accept. Which statement reveals its value on the server?



Answer

Correct Answer: Request.servervariables("HTTP_Accept")

Note: This Question is unanswered, help us to find answer for this one

277. Which of the following is true regarding the End method of the Response object?


Answer

Correct Answer: It stops the processing of the page and flushes the content

Note: This Question is unanswered, help us to find answer for this one

278. The language to be used for the ASP page can be specified:


Answer

Correct Answer: In the language property of the application object

Note: This Question is unanswered, help us to find answer for this one

279. Which of the following would be the most secure method to retain the state of a user?


Answer

Correct Answer: Session variables

Note: This Question is unanswered, help us to find answer for this one

280. When is the Session_OnStart event fired?


Answer

Correct Answer: Upon every request by each client for an ASP document belonging to the given application

Note: This Question is unanswered, help us to find answer for this one

281. What does the ScriptTimeout property do?



Answer

Correct Answer: It specifies the amount of time that a script can run before it times out

Note: This Question is unanswered, help us to find answer for this one

282. While creating and testing an ASP page, you receive an error while navigating backwards in a Recordset. What changes would you make to rectify the problem?



Answer

Correct Answer: Change the CursorType property of the recordset

Note: This Question is unanswered, help us to find answer for this one

283. What does the Server.MapPath method do?



Answer

Correct Answer: Translates a virtual path to a physical path

Note: This Question is unanswered, help us to find answer for this one

284. View the code below. In which collection will the "a" object be placed?

       Set Application("a") = Server.CreateObject("C1.Object")




Answer

Correct Answer: Application.Contents collection

Note: This Question is unanswered, help us to find answer for this one

285. The site you are programming for is switching from single-valued cookies to a dictionary cookie. The already issued cookies are valid for eight months, and you have to deal with the old and the new cookies. How can you differentiate between the two?



Answer

Correct Answer: By using the Haskeys property to see whether the cookie is a collection

Note: This Question is unanswered, help us to find answer for this one

286. Which of the following statements about ASP and XML is true?



Answer

Correct Answer: ASP scripts can be used to read and process XML data. They can also output XML. XSL is also supported

Note: This Question is unanswered, help us to find answer for this one

287. You are working with ASP and Microsoft SQL Server. You want to create new tables in your database through ASP pages. Which of the following is true?



Answer

Correct Answer: You can use ADOX to create tables

Note: This Question is unanswered, help us to find answer for this one

288. Which of the following code examples will write a cookie named "a" with the value "hello"?



Answer

Correct Answer: Response.cookies("a") = "hello"

Note: This Question is unanswered, help us to find answer for this one

289. What will be the output of the following code?

        dim i
        response.buffer = False
        response.write i



Answer

Correct Answer: A blank page will be displayed

Note: This Question is unanswered, help us to find answer for this one

290. You want to ensure that the value of a variable does not change and remains constant. How can you do this?



Answer

Correct Answer: Use the const keyword while declaring the variable

Note: This Question is unanswered, help us to find answer for this one

291. What is the error in the following code?

response.write "hello"
response.charset = 1252
response.write "there"


Answer

Correct Answer: Response.Charset is modifying the header and therefore should be the first statement

Note: This Question is unanswered, help us to find answer for this one

292. The IsClientConnected property can be used to:



Answer

Correct Answer: Stop processing of a page if the user is no longer viewing that page

Note: This Question is unanswered, help us to find answer for this one

293. When is the Session_OnEnd event fired?



Answer

Correct Answer: When the session times out

Note: This Question is unanswered, help us to find answer for this one

294. Which character is used to break a VBScript statement into multiple lines?

Answer

Correct Answer: _

Note: This Question is unanswered, help us to find answer for this one

295. Which of the following will hamper the efficiency of an ASP application?


Answer

Correct Answer: Making maximum use of Session variables

Note: This Question is unanswered, help us to find answer for this one

296. What is the Option Explicit statement used for?



Answer

Correct Answer: It forces explicit declaration of all variables in a script

Note: This Question is unanswered, help us to find answer for this one

297. You want to update the records in a database that match a certain criteria. You run a SQL Update statement through the Execute method of the Connection or Command object. How can you determine the number of rows affected by the Update statement?



Answer

Correct Answer: The Execute method has a parameter which returns the number of rows affected

Note: This Question is unanswered, help us to find answer for this one

298. Which of the following is not a valid error-handling statement?



Answer

Correct Answer: On Error Goto label ()

Note: This Question is unanswered, help us to find answer for this one

299. What will the following code do?

        for i = 0 to rs.fields.count
             response.write rs.fields(i).name                
        next

where rs is a recordset containing data from a table



Answer

Correct Answer: None of the above

Note: This Question is unanswered, help us to find answer for this one

300. The first field of a Recordset rs is phone. Which of the following statement can be used to display its value?


Answer

Correct Answer: All of the above

Note: This Question is unanswered, help us to find answer for this one

301. You need to enable/disable sessions on a page to page basis. Which statement will you give on each page to disable the sessions?


Answer

Correct Answer: ENABLESESSIONSTATE=FALSE 

Note: This Question is unanswered, help us to find answer for this one

302. The command Session.Contents.RemoveAll() will:



Answer

Correct Answer: Remove all variables from the Session.Contents collection

Note: This Question is unanswered, help us to find answer for this one

303. For what purpose is the HTMLEncode method of the server object used?



Answer

Correct Answer: For handling special characters entered by the user

Note: This Question is unanswered, help us to find answer for this one

304. You want to give two directives - EnableSessionState and Language in the same statement. What will the correct syntax be?



Answer

Correct Answer: &lt;% @ enablesessionstate = false language = vbscript %&gt;

Note: This Question is unanswered, help us to find answer for this one

305. Your ASP application communicates with a server that may not always be available. You need to be able to communicate asynchronously with the server. What technique/technology would you use?



Answer

Correct Answer: MSMQ

Note: This Question is unanswered, help us to find answer for this one

306. When is the application_onstart event fired?



Answer

Correct Answer: Upon the first request(after starting the web server) for an HTML or ASP document belonging to the given application

Note: This Question is unanswered, help us to find answer for this one

307. What does the Application.Lock method do?



Answer

Correct Answer: It locks the Application object, preventing other clients from altering any values in the Contents collection

Note: This Question is unanswered, help us to find answer for this one

308. What is the output of the following code?

        <%= now %>



Answer

Correct Answer: The current date and time of the server will be displayed

Note: This Question is unanswered, help us to find answer for this one

309. When are you most likely to use the Request.BinaryRead method?



Answer

Correct Answer: When an HTML form is being used to upload a file from the client's hard disk to the server's hard disk

Note: This Question is unanswered, help us to find answer for this one

310. What would be the correct reason for session variables to fail?



Answer

Correct Answer: The user has disabled cookies in his browser

Note: This Question is unanswered, help us to find answer for this one

311. A particular web site contains a lot of violence, bad language etc. What property of the response object would you use to define its content?



Answer

Correct Answer: PICS

Note: This Question is unanswered, help us to find answer for this one

312. How can you include spaces and other special characters in a query string?




Answer

Correct Answer: By using the URLEncode method of the server object

Note: This Question is unanswered, help us to find answer for this one

313. Which function would you not use in an Active Server Page?


Answer

Correct Answer: Date

Note: This Question is unanswered, help us to find answer for this one

314. What would be the fastest way of connecting to a database?



Answer

Correct Answer: DSN-less connection

Note: This Question is unanswered, help us to find answer for this one

315. What is the purpose of the global.asa file?



Answer

Correct Answer: It holds information that is global to the ASP application

Note: This Question is unanswered, help us to find answer for this one

316. What will be the output of the following code?

1   <%
2       num1=10
3       response.write("Before=" & num1)
4       call dbl(num1)
5       response.write(" After=" & num1)
6       sub dbl(byref num1)
7              num1=num1*2
8              response.write(" During=" & num1)
9       end sub
10  %>



Answer

Correct Answer: Before=10 During=20 After=20

Note: This Question is unanswered, help us to find answer for this one

317. You want to fill a list box with data from a database. What values would you assign to the CursorType and LockType properties of the Recordset object?



Answer

Correct Answer: CursorType = adopenforwardonly;LockType = adlockreadonly

Note: This Question is unanswered, help us to find answer for this one

318. Some statements regarding an ASP application are mentioned below. Which is the incorrect one?



Answer

Correct Answer: An ASP application is the same as a web site. A web site can have only one ASP application

Note: This Question is unanswered, help us to find answer for this one

319. While executing an ASP script, you receive an error message-

       Object doesn't support this property or method.

Which of the following could be the most probable cause of this error?



Answer

Correct Answer: There is a programming error in the ASP script

Note: This Question is unanswered, help us to find answer for this one

320. Your ASP file generates a lot of content. You do not want the user to see a blank page while the entire ASP file is being processed. You want the ASP file to send content to the user as and when it gets generated. How would you achieve this ?



Answer

Correct Answer: Use the Response.Flush method from time to time

Note: This Question is unanswered, help us to find answer for this one

321. What will the following code do?

        <% newdate = dateadd("mm",4,now) %>



Answer

Correct Answer: An error will be generated

Note: This Question is unanswered, help us to find answer for this one

322. What will be the output of the following code?

       <% response.write(application("a"))%>
       <%= application.value("b") %>



Answer

Correct Answer: It will display the values of both application variables a and b

Note: This Question is unanswered, help us to find answer for this one

323. Is it a good practice to explicitly convert the datatypes of session variables, form variables and querystring variables by using conversion functions before performing operations on them?



Answer

Correct Answer: Yes, because these variables are of Variant type but their sub type is always String

Note: This Question is unanswered, help us to find answer for this one

324. What is the ObjectContext object used for?



Answer

Correct Answer: To commit or abort a transaction managed by Microsoft Transaction Server

Note: This Question is unanswered, help us to find answer for this one

325. You want to perform a batch update using the Batchupdate method. What values would you assign to the CursorType and LockType properties of the Recordset object?



Answer

Correct Answer: CursorType = adopenkeyset&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;LockType = adlockbatchoptimistic

Note: This Question is unanswered, help us to find answer for this one

326. You want to send the string "hello there" as a Querystring parameter called 'greetings' to a web page named 'greetings.asp'. Which of the following statements is correct?



Answer

Correct Answer: Response.redirect "greetings.asp?greetings=" &amp; urlencode("hello there")

Note: This Question is unanswered, help us to find answer for this one

327. Consider the following events:

1. Page_Load
2. Page_Unload
3. Control Event
4. Page_Init

What is the order of their execution?



Answer

Correct Answer: 4,1,3,2

Note: This Question is unanswered, help us to find answer for this one

328. Which statement will prevent a browser from caching an .aspx page?

Answer

Correct Answer: Response.NoCache = "true";

Note: This Question is unanswered, help us to find answer for this one

329. Which property is used to ensure that the encoded and encrypted viewstate is not tampered with?

Answer

Correct Answer: EnableViewStateMac

Note: This Question is unanswered, help us to find answer for this one

330. Which of the following are the primary request headers involved in Web API content negotiation?

Answer

Correct Answer: Accept, Accept-Charset, Accept-Encoding, Accept-Language

Note: This Question is unanswered, help us to find answer for this one

331. Which of the following is the file extension for ashx files?

Answer

Correct Answer: custom HTTP handlers

Note: This Question is unanswered, help us to find answer for this one

332. Which XML format is used to render DataSet object contents to XML?

Answer

Correct Answer: DiffGram

Note: This Question is unanswered, help us to find answer for this one

333. Which infrastructure supports these dynamic operations at run time?

Answer

Correct Answer: DLR

Note: This Question is unanswered, help us to find answer for this one

334. Which HTTP status code returns by Response.Redirect("...")?

Answer

Correct Answer: 302

Note: This Question is unanswered, help us to find answer for this one

335. How can a programer set a Query using Jquery?

Answer

Correct Answer: Add jquery file to the application.

Note: This Question is unanswered, help us to find answer for this one

336. How can a programmer protect the asp:login object from SQL Injection attacks?

Answer

Correct Answer: It is protected by default.

Note: This Question is unanswered, help us to find answer for this one

337. Which view engine(s) does ASP.NET MVC use by default?

Answer

Correct Answer: WebForm And Razor

Note: This Question is unanswered, help us to find answer for this one

338. Which of the following is the correct use of "_" in ASP.NET?

Answer

Correct Answer: Line break

Note: This Question is unanswered, help us to find answer for this one

339. Which attribute is used in the @Page directive to enforce compatibility between ASP.NET and old COM components that do not support MTA model?

Answer

Correct Answer: aspcompat

Note: This Question is unanswered, help us to find answer for this one

340. Which of the following are the built-in WCF message encoder implementations?

Answer

Correct Answer: TextMessageEncoder, BinaryMessageEncoder, and MtomMessageEncoder

Note: This Question is unanswered, help us to find answer for this one

341. Page navigation means moving from one page to another page in your web site and another. Which feature allows for many ways to navigate from one page to another in ASP.NET?

Answer

Correct Answer: Client-side navigation

Note: This Question is unanswered, help us to find answer for this one

342. Which method is used to check for integrity of data in a Request object?

Answer

Correct Answer: HttpRequest.ValidateInput(

Note: This Question is unanswered, help us to find answer for this one

343. Which of the following must be done before consuming a web service?

Answer

Correct Answer: Build a proxy library by using the wsdl.exe utility.

Note: This Question is unanswered, help us to find answer for this one

344. Which of the following techniques can be used to implement the Client-Based state management?

Answer

Correct Answer: All of these

Note: This Question is unanswered, help us to find answer for this one

345. Which is the 1st method that is fired during the page load?

Answer

Correct Answer: Init()

Note: This Question is unanswered, help us to find answer for this one

346. Which method is used to load an assembly dynamically?

Answer

Correct Answer: Assembly.Load()

Note: This Question is unanswered, help us to find answer for this one

347. Where does ASP.NET store SessionIDs by default?

Answer

Correct Answer: Cookies

Note: This Question is unanswered, help us to find answer for this one

348. Which of the following is the same as "<%=" ?

Answer

Correct Answer: Response.Write

Note: This Question is unanswered, help us to find answer for this one

349. Which method of Global.aspx will handle application's un-handled exceptions?

Answer

Correct Answer: Application_Error

Note: This Question is unanswered, help us to find answer for this one

350. Which of the following is not a WCF service behavior?

Answer

Correct Answer: Endpoint addresses

Note: This Question is unanswered, help us to find answer for this one

351. In ASP.NET, which of the following low level Request and Response API is used to service incoming Http requests?

Answer

Correct Answer: HttpHandler

Note: This Question is unanswered, help us to find answer for this one

352. Which delimiters surround ASP server scripts?

Answer

Correct Answer: <%...%>

Note: This Question is unanswered, help us to find answer for this one

353. How does the ASP.NET run-time detect the user session id ?

Answer

Correct Answer: It reads the session id stored in the HTTP Request cookie.

Note: This Question is unanswered, help us to find answer for this one

354. Which feature in ASP.NET 2.0 is used to fire a normal postback to a different page in the application?

Answer

Correct Answer: Cross Page Posting

Note: This Question is unanswered, help us to find answer for this one

355. Which ASP.NET feature separates the HTML output from program logic?

Answer

Correct Answer: Code-behind

Note: This Question is unanswered, help us to find answer for this one

356. Which Microsoft technology preceded ASP.NET?

Answer

Correct Answer: Active Server Pages

Note: This Question is unanswered, help us to find answer for this one

357. Which of the following is the logical and physical boundary created around every .NET application?

Answer

Correct Answer: Application Domain

Note: This Question is unanswered, help us to find answer for this one

358. Which of the following denotes the web control associated with the Table control function of ASP.NET?

Answer

Correct Answer: TableRow (ANS)

Note: This Question is unanswered, help us to find answer for this one

359. Which is the difference in Application State and View State?

Answer

Correct Answer: Application State is stored on the server while ViewState is stored on the client machine.

Note: This Question is unanswered, help us to find answer for this one

360. How can a programmer register a custom server control to a Web page?

Answer

Correct Answer: @Register

Note: This Question is unanswered, help us to find answer for this one

361. Which is the parent class of the Web server control?

Answer

Correct Answer: System.Web.UI.Control

Note: This Question is unanswered, help us to find answer for this one

362. How can a programmer show the entire validation error message in a message box on the client side?

Answer

Correct Answer: In the ValidationSummary control set property called “ShowMessageBox” to true.

Note: This Question is unanswered, help us to find answer for this one

363. How many forms can be added to a aspx page?

Answer

Correct Answer: 1

Note: This Question is unanswered, help us to find answer for this one

364. Which stage of page life-cycle occurs last?

Answer

Correct Answer: Unload

Note: This Question is unanswered, help us to find answer for this one

365. Which of the following is/are the methods to author pages in ASP.NET?

Answer

Correct Answer: Both In-Line Code and Code Behind

Note: This Question is unanswered, help us to find answer for this one

366. Which of the following identifies a postback?

Answer

Correct Answer: use IsPostback

Note: This Question is unanswered, help us to find answer for this one

367. Which is the difference between machine.config and web.config?

Answer

Correct Answer: The Settings made in web.config are only applicable for that particular application. The settings made in machine.config can be applied to whole .net framework.

Note: This Question is unanswered, help us to find answer for this one

368. Which of the following is the syntax to inherit from a class in C#?

Answer

Correct Answer: Place a colon and then the name of the base class

Note: This Question is unanswered, help us to find answer for this one

369. Which default file type is used on a web page in ASP.NET?

Answer

Correct Answer: *.aspx

Note: This Question is unanswered, help us to find answer for this one

370. Can a programmer write serverside code inside an aspx page?

Answer

Correct Answer: Yes, use the <% %>.

Note: This Question is unanswered, help us to find answer for this one

371. Which property of the Page class is used to determine if the page has posted back?

Answer

Correct Answer: IsPostBack

Note: This Question is unanswered, help us to find answer for this one

372. How can a programmer display all validation messages in one control?

Answer

Correct Answer: ValidationSummary

Note: This Question is unanswered, help us to find answer for this one

373. In which of the following forms does Postback occur?

Answer

Correct Answer: Webforms

Note: This Question is unanswered, help us to find answer for this one

374. In the ASP.NET server control, which of the following provides an alternative way of displaying text on web page?

Answer

Correct Answer: < asp:label >

Note: This Question is unanswered, help us to find answer for this one

375. When an .aspx page is requested from the web server, in which format will the the output be rendered to the browser?

Answer

Correct Answer: HTML

Note: This Question is unanswered, help us to find answer for this one

376. Which of the following is used to validate complex string patterns (i.e. email)?

Answer

Correct Answer: Regular Expressions

Note: This Question is unanswered, help us to find answer for this one

377. Which of the following can be used to get info from a form that is submitted using the post method?

Answer

Correct Answer: Request.Form

Note: This Question is unanswered, help us to find answer for this one

378. Which of the following application events is fired at the beginning of each request to the server?

Answer

Correct Answer: Application_BeginRequest

Note: This Question is unanswered, help us to find answer for this one

379. Which property is used to support Cross Page Scripting in ASP.NET?

Answer

Correct Answer: PostBackUrl

Note: This Question is unanswered, help us to find answer for this one

380. Which of the following SessionState Modes causes the Session_End event to fire?

Answer

Correct Answer: Inproc

Note: This Question is unanswered, help us to find answer for this one

381. In ASP.NET, what is the separation of presentation and content?

Answer

Correct Answer: Code Behind

Note: This Question is unanswered, help us to find answer for this one

382. Which threading model is used in ASP.NET?

Answer

Correct Answer: MTA

Note: This Question is unanswered, help us to find answer for this one

383. Which of the following is the default timeout for a Cookie?

Answer

Correct Answer: 30 minutes

Note: This Question is unanswered, help us to find answer for this one

384. Which of the following is used to sign out from forms authentication?

Answer

Correct Answer: FormsAuthentication.Signout()

Note: This Question is unanswered, help us to find answer for this one

385. Which of the following is the default scripting language in ASP.NET?

Answer

Correct Answer: VBScript

Note: This Question is unanswered, help us to find answer for this one

386. Which of the following is the property to get a client side id for a control at run time?

Answer

Correct Answer: ClientID

Note: This Question is unanswered, help us to find answer for this one

387. Which type is used to manage server-side state?

Answer

Correct Answer: All these

Note: This Question is unanswered, help us to find answer for this one

388. Which method is used to kill explicitly a user's session?

Answer

Correct Answer: Session.Abandon() method

Note: This Question is unanswered, help us to find answer for this one

389. Which Style property of the GridView Control is used for formatting Gridview Pages?

Answer

Correct Answer: PagerStyle

Note: This Question is unanswered, help us to find answer for this one

390. How does a programmer secure a whole ASP.NET MVC4 website?

Answer

Correct Answer: Registering System.Web.Mvc.AuthorizeAttribute() in RegisterGlobalFilters

Note: This Question is unanswered, help us to find answer for this one

391. Which class does the ASP.NET web form class inherit from by default?

Answer

Correct Answer: System.Web. UI.Page

Note: This Question is unanswered, help us to find answer for this one

392. What is the svc extension used for?

Answer

Correct Answer: Windows Communication Foundation service file

Note: This Question is unanswered, help us to find answer for this one

393. Which of the following is the method name to make upper case to string value?

Answer

Correct Answer: ToUpper()

Note: This Question is unanswered, help us to find answer for this one

394. Which of the following is used to disable client side script in validators?

Answer

Correct Answer: Set EnableClientScript property to false.

Note: This Question is unanswered, help us to find answer for this one

395. In the following web.config directive: Is "Off" case-sensitive?

Answer

Correct Answer: Yes

Note: This Question is unanswered, help us to find answer for this one

396. Which of the following differentiates a UserControl from a Custom Server control?

Answer

Correct Answer: UserControl does not require the use of the @Register directive; a Custom Server control does require it.

Note: This Question is unanswered, help us to find answer for this one

397. Which of the following are true about System.Security.Cryptography under version 3.5 of the framework?

Answer

Correct Answer: Cryptography Next Generation (CNG) classes are supported on XP andVista systems.

Note: This Question is unanswered, help us to find answer for this one

398. Can we have multiple web.config files in a web application?

Answer

Correct Answer: True

Note: This Question is unanswered, help us to find answer for this one

399. What method is used to explicitly kill a users session?

Answer

Correct Answer: Session.Abandon();

Note: This Question is unanswered, help us to find answer for this one

400. Which control does not have any event?

Answer

Correct Answer: Image

Note: This Question is unanswered, help us to find answer for this one

401. which is the first event which gets triggers or fires in an Aspx Page?

Answer

Correct Answer: Page_Init()

Note: This Question is unanswered, help us to find answer for this one

402. Which type is used to manage client-side state?

Answer

Correct Answer: All these

Note: This Question is unanswered, help us to find answer for this one

403. Can we access and change value of a control which is defined in a Master page from the child page?

Answer

Correct Answer: True

Note: This Question is unanswered, help us to find answer for this one

404. If a developer of ASP.NET defines style information in a common location. Then that location is called as

Answer

Correct Answer: Theme

Note: This Question is unanswered, help us to find answer for this one

405. What type of links "http://test.com/test.aspx"?

Answer

Correct Answer: Absolute

Note: This Question is unanswered, help us to find answer for this one

406. Which method do you use to enforce garbage collection in .NET?

Answer

Correct Answer: System.GC.Collect() method

Note: This Question is unanswered, help us to find answer for this one

407. When decorating a function with async, what is the appropriate return type?

Answer

Correct Answer: Task<>

Note: This Question is unanswered, help us to find answer for this one

408. The property used to set absolute cache expiration in ASP.NET is:

Answer

Correct Answer: Cache.NoSlidingExpiration

Note: This Question is unanswered, help us to find answer for this one

409. Which one is faster way of resolving paths?

Answer

Correct Answer: Request.PhysicalApplicationPath

Note: This Question is unanswered, help us to find answer for this one

410. Which of the following statements is true?

Answer

Correct Answer: IEnumerable is a pull based sequence

Note: This Question is unanswered, help us to find answer for this one

411. Asynchronous behavior is related to

Answer

Correct Answer: None of these

Note: This Question is unanswered, help us to find answer for this one

412. How does Web API OData support partial updates?

Answer

Correct Answer: Delta parameter in controller action

Note: This Question is unanswered, help us to find answer for this one

413. How do you turn off cookies for a page?

Answer

Correct Answer: Set Cookie.Discard property to true

Note: This Question is unanswered, help us to find answer for this one

414. What are the strategies for partitioning threads in a PLINQ query?

Answer

Correct Answer: Chunked, ranged or hashed

Note: This Question is unanswered, help us to find answer for this one

415. Which of the following locking techniques is considered speculative?

Answer

Correct Answer: SpinWait

Note: This Question is unanswered, help us to find answer for this one

416. Under what condition(s) should a controller action be made async?

Answer

Correct Answer: IO intensive

Note: This Question is unanswered, help us to find answer for this one

417. What can we specify in the web.config to apply Themes to an ASP.NET application?

Answer

Correct Answer: <pages theme="Windows7" />

Note: This Question is unanswered, help us to find answer for this one

418. Which of the following is not a Web Form Event in ASP.NET: Page_Dispose Page_Error Page_AbortTransaction Page_CommitTransaction

Answer

Correct Answer: Page_Dispose

Note: This Question is unanswered, help us to find answer for this one

419. In ASP.NET if you want to allows page developers a way to specify static connections in a content page then the class used is

Answer

Correct Answer: ProxyWebPartManager

Note: This Question is unanswered, help us to find answer for this one

420. False or True? Using DateTime.Now is much faster than using the Timestamp property

Answer

Correct Answer: False

Note: This Question is unanswered, help us to find answer for this one

421. How can Web API OData support be implemented?

Answer

Correct Answer: Controller extends ODataController

Note: This Question is unanswered, help us to find answer for this one

422. Which of the following statements is true about the GridView in .NET 4.5?

Answer

Correct Answer: Strongly typed object binding

Note: This Question is unanswered, help us to find answer for this one

423. What is correct Syntax for applying FAViCON ICON to your web page.

Answer

Correct Answer: <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon"/> <link rel="icon" href="/favicon.ico" type="image/x-icon"/>

Note: This Question is unanswered, help us to find answer for this one

424. Which of the following events are correctly ordered according to the Application lifecycle?

Answer

Correct Answer: BeginRequest, AuthenticateRequest, AuthorizeRequest, ResolveRequestCache, AcquireRequestState, ProcessRequest, ReleaseRequestState, UpdateRequestCache, EndRequest.

Note: This Question is unanswered, help us to find answer for this one

425. What is wrong with this code? string email = emailTextbox; string SQL = "select * from users where username = "+email+" "; SqlCommand myCommand = new SQLCommand(SQL, myConnection) try { myConnection.Open(); SqlDataReader myReader=myCommand.ExecuteReader(); if (myReader.Read()) { ...

Answer

Correct Answer: the string email will not have the right value and the SQL is subject to injection attacks.

Note: This Question is unanswered, help us to find answer for this one

426. What are the three IIS isolation levels?

Answer

Correct Answer: Low, Medium and High

Note: This Question is unanswered, help us to find answer for this one

427. Which method has been introduced in ASP.NET 4.0 to redirect a page permanently?

Answer

Correct Answer: RedirectPermanent() method

Note: This Question is unanswered, help us to find answer for this one

428. Which property is used to retrieve a username in Windows Authentication?

Answer

Correct Answer: System.Environment.UserName

Note: This Question is unanswered, help us to find answer for this one

429. I have a property in my code-behind get { return (Custom)Session["Custom"]; } set { Session["Custom"] = value; } and I receive a serialization error What are the possible solutions?

Answer

Correct Answer: All of these will work

Note: This Question is unanswered, help us to find answer for this one

430. What is the maximum number of cookies that can be allowed to a web site?

Answer

Correct Answer: 20

Note: This Question is unanswered, help us to find answer for this one

431. which of the following is not ASP.NET directives?

Answer

Correct Answer: web

Note: This Question is unanswered, help us to find answer for this one

432. When would WCF be a better solution than Web API?

Answer

Correct Answer: Need for SOAP

Note: This Question is unanswered, help us to find answer for this one

433. How can you disable client-side validation in ASP.NET?

Answer

Correct Answer: By setting the EnableClientScript property to false

Note: This Question is unanswered, help us to find answer for this one

434. In which of the following SessionState Modes the Session_End event fires?

Answer

Correct Answer: Inproc

Note: This Question is unanswered, help us to find answer for this one

435. Contents of assembly file can be investigated using

Answer

Correct Answer: ILDASM.exe

Note: This Question is unanswered, help us to find answer for this one

436. Which two new properties are added in ASP.NET 4.0 Page class?

Answer

Correct Answer: MetaKeyword and MetaDescription

Note: This Question is unanswered, help us to find answer for this one

437. Which one is the first step in Asp.Net MVC request cycle.

Answer

Correct Answer: Routing

Note: This Question is unanswered, help us to find answer for this one

438. In the following example, is viewstate being set? (Test.aspx - viewstate enabled) (Test.aspx.cs) protected override void OnLoad(EventArgs args) { this.LabelTest.Text = “changed”; base.OnLoad(e); }

Answer

Correct Answer: Yes

Note: This Question is unanswered, help us to find answer for this one

439. Can you run a web application without the web.config file?

Answer

Correct Answer: Yes

Note: This Question is unanswered, help us to find answer for this one

440. You are developing ASP.NET templated server control. You need to ensure that a new ID namespace is created within the page control hierarchy when the control is added to the page. Which interface should you implement on the control?

Answer

Correct Answer: INamingContainer

Note: This Question is unanswered, help us to find answer for this one

441. In LINQ what is the difference in .Ancestor and .Parent?

Answer

Correct Answer: Parent is the immediate node a level above, Ancestors is all nodes all levels above.

Note: This Question is unanswered, help us to find answer for this one

442. _______ is a special subfolder within the windows folder that stores the shared .NET component?

Answer

Correct Answer: GAC

Note: This Question is unanswered, help us to find answer for this one

443. True or False: Without Web.config file application will not compile or Run.

Answer

Correct Answer: False

Note: This Question is unanswered, help us to find answer for this one

444. True or False: It is true that lines are reference type?

Answer

Correct Answer: True

Note: This Question is unanswered, help us to find answer for this one

445. Which formats can Web API work with?

Answer

Correct Answer: XML

Note: This Question is unanswered, help us to find answer for this one

446. How can an MVC View be protected from CSRF?

Answer

Correct Answer: @Html.AntiForgeryToken() in View and ValidateAntiForgeryToken attribute on controller action

Note: This Question is unanswered, help us to find answer for this one

447. Can MVC, Web Forms and Web API be mixed in the same project?

Answer

Correct Answer: Yes

Note: This Question is unanswered, help us to find answer for this one

448. How do you make a controller action async?

Answer

Correct Answer: return an async Task from controller action while awaiting within the method

Note: This Question is unanswered, help us to find answer for this one

449. Which of the following statements best describes setting up an async page in .NET 4.5?

Answer

Correct Answer: async=true on page directive, RegisterAsyncTask in page load and async method

Note: This Question is unanswered, help us to find answer for this one

450. Which of the following contains one or more variables that are accessed through sequential indices?

Answer

Correct Answer: Arrays

Note: This Question is unanswered, help us to find answer for this one

451. Can Web API be hosted in its own process without IIS?

Answer

Correct Answer: Yes

Note: This Question is unanswered, help us to find answer for this one

452. The first method that is executed in the Page life cycle in ASP.NET is:

Answer

Correct Answer: PreInit

Note: This Question is unanswered, help us to find answer for this one

453. Where is the ViewState information stored?

Answer

Correct Answer: in the HTML hidden fields.

Note: This Question is unanswered, help us to find answer for this one

454. How do you enable impersonation in the web.config file?

Answer

Correct Answer: <identity impersonate = "true" />

Note: This Question is unanswered, help us to find answer for this one

455. What is default timeout of session in asp.net?

Answer

Correct Answer: 20 min

Note: This Question is unanswered, help us to find answer for this one

456. In ASP.Net, session is maintained using the methods:

Answer

Correct Answer: (all of these)

Note: This Question is unanswered, help us to find answer for this one

457. Which of the following is not a .NET compatible language?

Answer

Correct Answer: Java

Note: This Question is unanswered, help us to find answer for this one

458. ASP.NET stores membership, role management, and profile information in which database?

Answer

Correct Answer: aspnetdb

Note: This Question is unanswered, help us to find answer for this one

459. In which event are the controls fully loaded?

Answer

Correct Answer: Page.Load()

Note: This Question is unanswered, help us to find answer for this one

460. Which of the following controls is used to validate that two fields are equal?

Answer

Correct Answer: CompareValidator

Note: This Question is unanswered, help us to find answer for this one

461. In Asp.Net Server.MapPath(".") points to which location

Answer

Correct Answer: points to the location where your project stored

Note: This Question is unanswered, help us to find answer for this one

462. Which of the following file types is associted with ASP.NET User controls?

Answer

Correct Answer: .ascx

Note: This Question is unanswered, help us to find answer for this one

463. Which attribute must be set on the validator control for the validator to work?

Answer

Correct Answer: ControlToValidate

Note: This Question is unanswered, help us to find answer for this one

464. Which HTML control property should be set to access control from code behind?

Answer

Correct Answer: Runat = "Server"

Note: This Question is unanswered, help us to find answer for this one

465. Which of the following ASP.NET directories stores class files (.cs) by default?

Answer

Correct Answer: App_Code

Note: This Question is unanswered, help us to find answer for this one

466. Which version of ASP .NET MVC has built-in support for mobile targeting?

Answer

Correct Answer: MVC 4

Note: This Question is unanswered, help us to find answer for this one

467. Can you set which type of comparison you want to perform by the CompareValidator control?

Answer

Correct Answer: Yes

Note: This Question is unanswered, help us to find answer for this one

468. Which method of the ServiceController class will allow you to send a command to the service?

Answer

Correct Answer: ExecuteCommand()

Note: This Question is unanswered, help us to find answer for this one

469. What is ASP.Net

Answer

Correct Answer: Server Side Technology

Note: This Question is unanswered, help us to find answer for this one

470. Which of the following is a property all the ASP.NET controls have?

Answer

Correct Answer: runat

Note: This Question is unanswered, help us to find answer for this one

471. What is the extension of a web user control file?

Answer

Correct Answer: .Ascx

Note: This Question is unanswered, help us to find answer for this one

472. Which of these forms is used in ASP.NET?

Answer

Correct Answer: Webforms

Note: This Question is unanswered, help us to find answer for this one

473. Where are private assemblies stored in ASP.NET?

Answer

Correct Answer: application / bin directory

Note: This Question is unanswered, help us to find answer for this one

search
ASP.NET Subjects