MCQOPTIONS
 Saved Bookmarks
				This section includes 228 Mcqs, each offering curated multiple-choice questions to sharpen your Computer Science Mcqs knowledge and support exam preparation. Choose a topic below to get started.
| 151. | 
                                    How many readers can simultaneously read data with ReaderWriterLock if there is no writer locks apply? | 
                            
| A. | 9 | 
| B. | 11 | 
| C. | 13 | 
| D. | No Limit | 
| Answer» E. | |
| 152. | 
                                    Which of the following is true ? 1. AJAX is a platform-independent technology 2. AJAX can work with web application 3. AJAX can only work with ASP.NET 4. AJAX is a platform-dependent technology | 
                            
| A. | 1, 2 | 
| B. | 1,2,3 | 
| C. | 1,3,4 | 
| D. | None of the above | 
| Answer» B. 1,2,3 | |
| 153. | 
                                    Which of the following are value types? | 
                            
| A. | String | 
| B. | System .Value | 
| C. | System.Drawing | 
| D. | System.Drawing.Point | 
| Answer» E. | |
| 154. | 
                                    When the garbage collector runs. | 
                            
| A. | It runs automatically | 
| B. | EveryDay | 
| C. | Every alternate day | 
| D. | When IIS restart. | 
| Answer» B. EveryDay | |
| 155. | 
                                    An assembly must have an permission to connect with web server is? | 
                            
| A. | socketPermission | 
| B. | DnsPermission | 
| C. | WebPermission | 
| D. | TCPPermission | 
| Answer» D. TCPPermission | |
| 156. | 
                                    Which control is required for every page that have AJAX Extensions for ASP.NET? | 
                            
| A. | UpdatePanel | 
| B. | ScriptManager | 
| C. | ContentPanel | 
| D. | None of the above | 
| Answer» C. ContentPanel | |
| 157. | 
                                    AnUpdatePanel control defined on a page. Button control is placed outside of the UpdatePanel. How to cause the UpdatePanel to execute an update. | 
                            
| A. | Set the Trigger attribute of the UpdatePanel to the ID of the Button control. | 
| B. | Set the AsyncPostBackTrigger attribute of the Button control to the ID of theUpdatePanel. | 
| C. | Place the button control on the update panel without script manager. | 
| D. | Add an AsyncPostBackTrigger control to the Triggers section of the UpdatePanel. Set the ControlID attribute of the AsyncPostBackTrigger control to the | 
| Answer» E. | |
| 158. | 
                                    Which method is used to dynamically register client script from code? | 
                            
| A. | Page.ClientScript.RegisterClientScriptBlock | 
| B. | RegisterScript | 
| C. | Page.ClientScript | 
| D. | None of the above | 
| Answer» B. RegisterScript | |
| 159. | 
                                    You need to select a class that is optimized for key - based item retrieval from both small and large collections. Which class should you choose? | 
                            
| A. | OrderedDictionary class | 
| B. | HybridDictionary class | 
| C. | ListDictionary class | 
| D. | Hashtable class | 
| Answer» C. ListDictionary class | |
| 160. | 
                                    Which of the following is dictionary object? | 
                            
| A. | HashTable | 
| B. | SortedList | 
| C. | NameValueCollection | 
| D. | All of the above | 
| Answer» E. | |
| 161. | 
                                    You need to identify a type that meets the following criteria: • Is always a number. • Is not greater than 65,535. Which type should you choose? | 
                            
| A. | System.UInt16 | 
| B. | int | 
| C. | System.String | 
| D. | System.IntPtr | 
| Answer» B. int | |
| 162. | 
                                    Which delegate is required to start a thread with one parameter? | 
                            
| A. | ThreadStart | 
| B. | ParameterizedThreadStart | 
| C. | ThreadStartWithOneParameter | 
| D. | None of the above | 
| Answer» C. ThreadStartWithOneParameter | |
| 163. | 
                                    For building new types at runtime which class can be used? | 
                            
| A. | System | 
| B. | System.Object | 
| C. | System.NewClass | 
| D. | System.Reflection.Emit. | 
| Answer» E. | |
| 164. | 
                                    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 | |
| 165. | 
                                    Which of the following statements are correct? 1. Indexers enable objects to be indexed in a similar manner to arrays. 2. The this keyword is used to define the indexers. 3. Indexers can be overloaded. 4. Indexer cannot be used in interface | 
                            
| A. | 1, 2 | 
| B. | 3 | 
| C. | 1,2,3 | 
| D. | None of the above | 
| Answer» D. None of the above | |
| 166. | 
                                    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 | |
| 167. | 
                                    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. | |
| 168. | 
                                    Choose the correct one | 
                            
| A. | Variables introduced within a lambda expression are not visible in the outer method. | 
| B. | Variables introduced within a lambda expression are visible in the outer method. | 
| C. | The lambda should not contain the same number of parameters as the delegate type. | 
| D. | None of the above | 
| Answer» B. Variables introduced within a lambda expression are visible in the outer method. | |
| 169. | 
                                    Which file contains settings for all .NET application types, such as Windows, Console, ClassLibrary, and Web applications? | 
                            
| A. | Web.config | 
| B. | Machine.config | 
| C. | Global.asax | 
| D. | All of the above | 
| Answer» C. Global.asax | |
| 170. | 
                                    Choose the correct one. | 
                            
| A. | The return value of the lambda (if any) must be explicitly convertible to the delegate's return type | 
| B. | Each input parameter in the lambda must be implicitly convertible to its corresponding delegate parameter. | 
| C. | Lamda expression does not work with LINQ. | 
| D. | None of the above | 
| Answer» C. Lamda expression does not work with LINQ. | |
| 171. | 
                                    Choose the correct option. | 
                            
| A. | Dynamic type is non - static type. | 
| B. | Dynamic type is static type. | 
| C. | Implicit conversion does not work with type dynamic. | 
| D. | None of the above | 
| Answer» C. Implicit conversion does not work with type dynamic. | |
| 172. | 
                                    What types of Objects can you query using LINQ? | 
                            
| A. | DataTables and DataSets | 
| B. | Any .NET Framework collection that implements IEnumerable(T) | 
| C. | Collections that implement interfaces that inherit from IEnumerable(T) | 
| D. | All of the above | 
| Answer» E. | |
| 173. | 
                                    Which LINQ statement is used to merge two data sources to perform queries? | 
                            
| A. | where | 
| B. | select | 
| C. | join | 
| D. | group | 
| Answer» D. group | |
| 174. | 
                                    What types of shapes can LINQ query results be shaped into? 1. Collections of primitive types 2. Collections of complex types 3. Single types 4. Collections of anonymous types | 
                            
| A. | 1, 2, 4 | 
| B. | 1,2,3 | 
| C. | 1,3,4 | 
| D. | None of the above | 
| Answer» B. 1,2,3 | |
| 175. | 
                                    Which LINQ keyword is used to categorize results in a query? | 
                            
| A. | where | 
| B. | select | 
| C. | join | 
| D. | group | 
| Answer» E. | |
| 176. | 
                                    If you want to validate the email addresses, Social Security numbers, phone numbers, and dates types of data, which validation control will be used? | 
                            
| A. | RegularExpressionValidator | 
| B. | CompareValidator | 
| C. | RequiredFieldValidator | 
| D. | None of the above | 
| Answer» B. CompareValidator | |
| 177. | 
                                    Which property will you set for each RadioButton Control in the group? | 
                            
| A. | Specify the same GroupName for each RadioButton. | 
| B. | Specify the different GroupName for each RadioButton. | 
| C. | Specify the same GroupID for each RadioButton. | 
| D. | Specify the same ID for each RadioButton. | 
| Answer» B. Specify the different GroupName for each RadioButton. | |
| 178. | 
                                    Which object data is included in bookmarks and e-mailed URLs? | 
                            
| A. | ViewState | 
| B. | cookies | 
| C. | Query strings | 
| D. | All of the above | 
| Answer» D. All of the above | |
| 179. | 
                                    When should you use the OleDbConnection object? | 
                            
| A. | When connecting to an Oracle database. | 
| B. | When connecting to an Office Access database | 
| C. | When connecting to SQL Server 2000 | 
| D. | None of the above | 
| Answer» C. When connecting to SQL Server 2000 | |
| 180. | 
                                    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 | |
| 181. | 
                                    If you want that command object should returns XML data then which method of Command Object will be used? | 
                            
| A. | getXMLData | 
| B. | getXML | 
| C. | ExecuteXMLReader | 
| D. | None of the above. | 
| Answer» D. None of the above. | |
| 182. | 
                                    You are writing a page that contains an UpdatePanel for partial-page updates. You want that user should get the message “Processing is going on, please wait.” that the update is processing only if the update takes longer than 5 seconds. Which actions should you take? | 
                            
| A. | Add a ProgressBar control to the page. Set the Interval property to 5000. Set the text property as “Processing is going on, please wait.” | 
| B. | Add a Timer control to the page. Set the Interval property to 5000. Set its text property to Processing is going on, please wait.” | 
| C. | Add an UpdateProgress control to the UpdatePanel. Set its DisplayAfter property to 5000. Set its ProgressTemplate contents to read “Processing is go | 
| D. | None of the above. | 
| Answer» D. None of the above. | |
| 183. | 
                                    Windows-Based Authentication is well suited for ___________ . | 
                            
| A. | Intranet environment | 
| B. | Public web site | 
| C. | Desktop application | 
| D. | None of the above | 
| Answer» B. Public web site | |
| 184. | 
                                    You want to make a configuration setting change that will affect only the current Web application. Which file will you change? | 
                            
| A. | Global.asax | 
| B. | Web.config in the root of the Web application | 
| C. | Machine.config | 
| D. | All of the above | 
| Answer» C. Machine.config | |
| 185. | 
                                    Which programming model should you implement if you want to separate your server-side code from your client-side layout code in a Web page? | 
                            
| A. | Single-file model | 
| B. | Code-behind model | 
| C. | Inline model | 
| D. | Client-server model | 
| Answer» C. Inline model | |
| 186. | 
                                    Choose the correct option about DataSet object. | 
                            
| A. | Provides Disconnected mode | 
| B. | Can store multiple table simultaneously | 
| C. | Consumer Object | 
| D. | All of the above. | 
| Answer» E. | |
| 187. | 
                                    You are a Web developer for CareerRide. The data is stored in a Microsoft SQL Server 2005 database on a server named CareerPC and the Database name is TestDB. You connect to TestDB by using Windows Integrated authentication. You use a SqlConnection object to connect to the database. You need to create a connection string to TestDB in the instance of SQL Server named CareerPC. Which string should you use? | 
                            
| A. | “Data Source= CareerPC; Database=TestDB; Integrated Security=SSP1”. | 
| B. | “Data Source= CareerPC; Initial Catalog=TestDB; Integrated Security=SSP1”. | 
| C. | “Server= CareerPC; Database=TestDB; Integrated Security=SSP1”. | 
| D. | All of the above. | 
| Answer» E. | |
| 188. | 
                                    What is/are true about master page? | 
                            
| A. | Master page contains a directive instead of the normal directive. | 
| B. | ContentPlaceHolder control can be added only on master page. | 
| C. | You can add as many ContentPlaceHolders to a Master Page as you need. | 
| D. | All of the above. | 
| Answer» E. | |
| 189. | 
                                    ASP.NET Validation Control works at ________ . | 
                            
| A. | Client side only. | 
| B. | Server side only. | 
| C. | Both Client Side and Server Side | 
| D. | None of the above. | 
| Answer» D. None of the above. | |
| 190. | 
                                    What is/are true about master page? Choose the correct option. | 
                            
| A. | You can add more than one master page in a website. | 
| B. | Master page can be nested. | 
| C. | ContentPlaceHolder control is required on a content page. | 
| D. | Both A and B options are correct. | 
| Answer» E. | |
| 191. | 
                                    To implement a specified .NET Framework interface which directive is used? | 
                            
| A. | @Register | 
| B. | @Control | 
| C. | @Reference | 
| D. | @Implements | 
| Answer» E. | |
| 192. | 
                                    Which file is used to write the code to respond to the Application_Start event? | 
                            
| A. | Any ASP.NET web page with an .aspx extension | 
| B. | Web.config | 
| C. | Global.asax | 
| D. | None of the above. | 
| Answer» D. None of the above. | |
| 193. | 
                                    Which of the following is not an ASP.NET page event? | 
                            
| A. | Init | 
| B. | Load | 
| C. | Import | 
| D. | None of the above. | 
| Answer» D. None of the above. | |
| 194. | 
                                    When a User’s Session times out which event should you respond to? | 
                            
| A. | Application_Start | 
| B. | Session_End | 
| C. | Session_Start | 
| D. | Application_End | 
| Answer» C. Session_Start | |
| 195. | 
                                    You want to secure the connection strings contained within your Web.config file to ensure that no one can open the file easily and see the connection information. Which tool must you use to encrypt the connection strings? | 
                            
| A. | ASPNET_WP.EXE | 
| B. | ASPNET_REGSQL.EXE | 
| C. | ASPNET_REGIIS.EXE | 
| D. | None of the above. | 
| Answer» D. None of the above. | |
| 196. | 
                                    How do you execute multiple SQL statements using a DataReader? | 
                            
| A. | Call the ExecuteReader method of a single Command object twice. | 
| B. | Set the Command.CommandText property to multiple SQL statements delimited by a semicolon. | 
| C. | Set the Command.CommandType property to multiple result sets. | 
| D. | None of the above. | 
| Answer» C. Set the Command.CommandType property to multiple result sets. | |
| 197. | 
                                    A Master Page contains a ScriptManager control and a user wants the AJAX functionality on content page then which control is necessary on content page? | 
                            
| A. | AsyncPostBackTrigger | 
| B. | ScriptManager | 
| C. | ScriptManagerProxy | 
| D. | None of the above. | 
| Answer» D. None of the above. | |
| 198. | 
                                    By default, when you use Page Output Caching, at what location page is cached? | 
                            
| A. | Only on web server | 
| B. | Only on Client | 
| C. | Web server, any proxy servers, and browser | 
| D. | All of the above. | 
| Answer» D. All of the above. | |
| 199. | 
                                    Which Session Mode stores session Information in Current Application Domain? | 
                            
| A. | InProc | 
| B. | StateServer | 
| C. | SQLServer | 
| D. | Off | 
| Answer» B. StateServer | |
| 200. | 
                                    What are the different types of Session Mode in ASP.NET? | 
                            
| A. | InProc | 
| B. | StateServer | 
| C. | SQLServer | 
| D. | All of the above | 
| Answer» E. | |