

MCQOPTIONS
Saved Bookmarks
This section includes 220 Mcqs, each offering curated multiple-choice questions to sharpen your Computer Science knowledge and support exam preparation. Choose a topic below to get started.
101. |
What is the recommended method for securing sensitive connection string information? |
A. | Encrypting the data in the application configuration file |
B. | Using a code obfuscator |
C. | Using Integrated Security (Windows Authentication) |
D. | Querying the user for his or her credentials at run time |
Answer» D. Querying the user for his or her credentials at run time | |
102. |
What is the name of the Page object’s property that determines if a Web page is being requested without data being submitted to server? |
A. | IsCallback |
B. | IsReusable |
C. | IsValid |
D. | IsPostBack |
Answer» E. | |
103. |
What is the minimal information needed by a connection string to open a connection to a SQL Server 2000 or SQL Server 2005 database? 1. A valid data source 2. A valid provider name 3. A valid file path 4. Appropriate credentials or Integrated Security settings |
A. | 1, 2 |
B. | 1, 2, 3 |
C. | 1, 3 |
D. | 1, 4 |
Answer» E. | |
104. |
What is the last event of web page life cycle? |
A. | Page_Load |
B. | Page_LoadComplete |
C. | Page_Finish |
D. | Page_Unload |
Answer» E. | |
105. |
What is the fully qualified name of the base class of all server controls? |
A. | System.Web.UI.Control |
B. | System.Web.UI |
C. | System.Control |
D. | All of the above |
Answer» B. System.Web.UI | |
106. |
What is the file extension of web service in ASP.NET? |
A. | .ascx |
B. | .asmx |
C. | .aspx |
D. | .docx |
Answer» C. .aspx | |
107. |
What is the easiest way in Design view to create an event handler for the default event of a server control? |
A. | Open the code-behind page and write the code. |
B. | Right-click the control and select Create Handler. |
C. | Drag an event handler from the Toolbox to the desired control. |
D. | Double-click the control. |
Answer» E. | |
108. |
What is the difference between a Local Transaction and a Distributed Transaction? |
A. | Local transactions are performed on a single database table, but distributed transactions are performed on more than one database tables. |
B. | Local transactions are performed on a single database server, but distributed transactions can be performed across multiple database servers. |
C. | Local transactions are performed on a database on the local machine, but distributed transactions are performed on a database on a remote machine. |
D. | None of the above. |
Answer» C. Local transactions are performed on a database on the local machine, but distributed transactions are performed on a database on a remote machine. | |
109. |
What is the connection string’s key / value pair for using WindowsAuthentication in SQLServer 2000 and SQL Server 2005? |
A. | 1, 2 |
B. | 1, 2, 3 |
C. | 2, 3 |
D. | 1, 4 |
Answer» D. 1, 4 | |
110. |
What is Multiple Active Result Sets (MARS)? |
A. | It allows execution of multiple batches against Database on a single connection. |
B. | New feature of SQL SERVER 2005. Previous version of SQL Server does not support this feature. |
C. | Option A and B are correct. |
D. | None of the above. |
Answer» D. None of the above. | |
111. |
What is lamda expression? 1. Anonymous function 2. Can be used to create delegates 3. Named function 4. None |
A. | 1, 2 |
B. | 1, 2, 3 |
C. | 1, 3 |
D. | 4 |
Answer» B. 1, 2, 3 | |
112. |
What is jQuery? 1. jQuery is an open source library 2. It works client side. 3. jQuery is java technology. |
A. | 1, 2 |
B. | 1, 2, 3 |
C. | 1, 3 |
D. | None of the above |
Answer» B. 1, 2, 3 | |
113. |
What is Caspol? |
A. | Command line tool |
B. | Code access security policy tool |
C. | Case Tool |
D. | Command line tool & Code access security policy tool |
Answer» E. | |
114. |
What is a web application running on multiple servers called? |
A. | HTTP |
B. | Web Servers |
C. | Web Page |
D. | Web farm |
Answer» E. | |
115. |
What happens when you call the Close method of a connection object? 1. The connection is destroyed. 2. The connection is returned to the connection pool. 3. The StateChangeevent is fired. 4. All non - committed pending transactions are rolled back. |
A. | 1, 2 |
B. | 1,3 |
C. | 2, 3, 4 |
D. | All of the above |
Answer» D. All of the above | |
116. |
What happens in the Init event of a page? |
A. | ViewState is loaded on the page. |
B. | Each child control of the page is initialized to its design time values. |
C. | HTML is rendered. |
D. | None of the above. |
Answer» C. HTML is rendered. | |
117. |
What happen in the Web Page when Init event occur? |
A. | ViewState is loaded on the page. |
B. | Each child control of the page is initialized to its design time values. |
C. | HTML is rendered. |
D. | None of the above |
Answer» C. HTML is rendered. | |
118. |
What determines the connection pool that a connection should use? 1. A connection string 2. The identity or credentials of the user opening the connection 3. The database being connected to 4. The connection object used to connect to the database |
A. | 1, 2 |
B. | 1, 2, 3 |
C. | 1, 3 |
D. | 1, 4 |
Answer» B. 1, 2, 3 | |
119. |
What datatype is returned when calling the ExecuteScalar method of a command object? |
A. | System.Int32 |
B. | Object |
C. | No. of effected records |
D. | None of the above |
Answer» C. No. of effected records | |
120. |
What data type is returned when calling the ExecuteScalar method of a command object? |
A. | System.Int32 |
B. | Object |
C. | No of effected records. |
D. | None of the above. |
Answer» C. No of effected records. | |
121. |
What component do you need to enable for a user to add new web parts? |
A. | WebpartZone |
B. | CatalogZone |
C. | WebPartManager |
D. | WebManager |
Answer» C. WebPartManager | |
122. |
What ASP.NET object encapsulates the state of the client and the browser? |
A. | Application Object |
B. | Session Object |
C. | Response Object |
D. | Request Object |
Answer» C. Response Object | |
123. |
What are the types of Web Server Button Controls that can be created? |
A. | Only Submit buttons |
B. | Only Command buttons |
C. | Submit and command buttons |
D. | None of the above. |
Answer» D. None of the above. | |
124. |
What are the types of cookies? |
A. | Session cookies |
B. | Persistent cookies |
C. | Dummy cookies |
D. | Option A and B are correct |
Answer» E. | |
125. |
What are the three primary kinds of parameters are used while working with the Stored Procedure in ASP.NET? |
A. | Input, Integer, String |
B. | int, varchar, nvarchar |
C. | Input, Output, InputOutput |
D. | All of the above. |
Answer» D. All of the above. | |
126. |
What are the three primary kinds of parameters? |
A. | Input, Integer, String |
B. | Integer, String, DateTime |
C. | int, varchar, nvarchar |
D. | Input, Output, InputOutput |
Answer» E. | |
127. |
What are the three main objects of DataSet? |
A. | DataTable, DataColumn, and type. |
B. | DataTable, DataRelation, and DataAdapter. |
C. | DataTable, DataColumn, and DataRelation. |
D. | DataReader,DataAdapter, and Command. |
Answer» D. DataReader,DataAdapter, and Command. | |
128. |
What are the steps to create a DataTable programmatically? |
A. | Instantiate a new DataTable and add DataColumn objects to the DataTable. Columns Collection. |
B. | Run the Data Source Configuration Wizard. |
C. | Instantiate a new DataSet object. |
D. | None of the above. |
Answer» B. Run the Data Source Configuration Wizard. | |
129. |
What are the recommended techniques for enabling connection pooling on for a SQL Server 2000 or SQL Server 2005 database? 1. Setting the OLE DB Services connection string keyword to -4 2. Opening a connection and not explicitly disabling pooling 3. Setting the connection string keyword Pooling = True in the connection string 4. Using the Connection Pooling tab of the ODBC Data Source Administrator dialog Box |
A. | 1, 2 |
B. | 1, 2, 3 |
C. | 2, 3 |
D. | 1, 4 |
Answer» D. 1, 4 | |
130. |
What are the element of code access security? |
A. | Evidence,Permission |
B. | SQLSecurity |
C. | UserInterface |
D. | SQL Injection |
Answer» B. SQLSecurity | |
131. |
What are the different types of Session Mode in ASP.NET? |
A. | InProc |
B. | StateServer |
C. | SQLServer |
D. | All of the above |
Answer» E. | |
132. |
What are the Command Object Methods? |
A. | ExecuteNonQuery |
B. | ExecuteReader |
C. | ExecuteScalar |
D. | All of the above. |
Answer» E. | |
133. |
What are the client-side state management options that ASP.NET supports? |
A. | Application |
B. | Session |
C. | Querystring |
D. | Option a and b are correct |
Answer» D. Option a and b are correct | |
134. |
What are the advantages of AJAX? |
A. | AJAX is a platform-independent technology |
B. | It provides partial-page updates |
C. | Improved performance |
D. | All of the above |
Answer» E. | |
135. |
Validation events of server controls occur before the page is post back to the server. |
A. | True |
B. | False |
Answer» B. False | |
136. |
Using which type of stylesheet we can change the style of an element in the entire website? |
A. | Internal Stylesheet |
B. | External Stylesheet |
C. | Inline stylesheet |
D. | None of above |
Answer» C. Inline stylesheet | |
137. |
To perform asynchronous data access, what must be added to the connection string? |
A. | BeginExecute=true |
B. | MultiThreaded=true |
C. | MultipleActiveResultSets=true |
D. | Asynchronous=true |
Answer» E. | |
138. |
To kill a users session explicitly which of the following will you use? |
A. | Session.Close() |
B. | Session.End() |
C. | Session.Abondon() |
D. | Session.Discard() |
Answer» D. Session.Discard() | |
139. |
To implement a specified .NET Framework interface which directive is used? |
A. | @Register |
B. | @Control |
C. | @Reference |
D. | @Implements |
Answer» E. | |
140. |
To create your application on a remote server which option you will choose in ASP.NET? |
A. | File System |
B. | FTP |
C. | HTTPS |
D. | None of the above. |
Answer» C. HTTPS | |
141. |
Thread class has the following property. A. ManagedThreadID B. IsBackground C. IsBackgroundColor D. Abort |
A. | 1, 2 |
B. | 1, 4 |
C. | 4 |
D. | 1 ,2, 4 |
Answer» B. 1, 4 | |
142. |
There is a button on page name cancel and it should bypass validation when cancel button is clicked. What will you do? |
A. | set CausesValidation = false |
B. | set RemoveValidation=true |
C. | set cancel=true |
D. | None of the above |
Answer» B. set RemoveValidation=true | |
143. |
The UpdatePanel supports two types of triggers: AsyncPostBackTrigger and PostBackTrigger. Choose the correct option regarding working of these triggers. |
A. | AsyncPostBackTrigger causes an asynchronous (Ajax) postback. |
B. | PostBackTrigger causes a normal entire-page postback. |
C. | AsyncPostBackTrigger causes a normal entire-page postback. |
D. | Option A and B are Correct. |
Answer» E. | |
144. |
The three statements are given below about DataSet and DataReader, choose the correct option according to the statement. Statement 1: DataSet Provides Disconnected environment but DataReader provides Connected environment. Statement 2: DataSet Provides Connected environment but DataReader provides Disconnected environment. Statement 3: DataSet Can store multiple table simultaneously but DataReader Supports a single table based on a single SQL query. |
A. | Only Statement 1 is correct. |
B. | Statement 1 and 2 is correct. |
C. | Statement 2 and 3 is correct. |
D. | Statement 1 and 3 is correct. |
Answer» E. | |
145. |
The best way for handling exception when dealing with a database connection? |
A. | Implement a try / catch block that catches System.Exceptions. |
B. | Implementing custom error page. |
C. | Implement a try / catch block that catches individual exception types, such as SQLException. |
D. | Display an error message. |
Answer» B. Implementing custom error page. | |
146. |
Reflection can be used when? |
A. | To access attributes in your program's metadata |
B. | To create type at compile time |
C. | To access attributes at compile time. |
D. | None of the above |
Answer» B. To create type at compile time | |
147. |
Range Validator control in ASP.NET supports which type? |
A. | Integer |
B. | String |
C. | Currency |
D. | All of the above |
Answer» E. | |
148. |
Properties in .NET can be declare as 1. Static, Protected internal, Virtual 2. Public, internal, Protected internal 3. Only public 4. None |
A. | 1, 2 |
B. | 3 |
C. | 1, 2, 3 |
D. | 4 |
Answer» B. 3 | |
149. |
On what object would you set the properties to create a primary key for a DataTable? |
A. | DataRelation |
B. | DataColumn |
C. | DataSet |
D. | DataTable |
Answer» D. DataTable | |
150. |
OleDbConnectionobject works with? 1. When connecting to an Oracle database 2. When connecting to an Office Access database 3. When connecting to SQL Server 6.x or later 4. When connecting to SQL Server 2000 |
A. | 1, 2 |
B. | 2, 3 |
C. | 1, 3 |
D. | 4 |
Answer» C. 1, 3 | |