ASP NET Questions

Q.  Why should you write the cleanup code in Finally block?

a. Compiler throws an error if you close the connection in try block.
b. Resource cannot be destroyed in catch block.
c. Finally blocks run whether or not exception occurs.
d. All of the above


ANSWER: See Answer
 
No explanation is available for this question!
MCQs:  How do I explicitly turn on connection pooling for an OLE DB data source?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  What property contains the actual error message returned by SQL Server? 1. SqlException.Source 2. SqlException.Message 3. SqlError.Class 4. SqlError.Message
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  What is the connection string’s key / value pair for using WindowsAuthentication in SQLServer 2000 and SQL Server 2005?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  What should you do to access the returned tabular data after starting execution of a command that runs asynchronously? (Choose all that apply.) 1. Call the EndExecuteNonQuerymethod. 2. Call the EndExecuteReadermethod. 3. Wait for the StatementCompletedevent to fire and iterate through the DataReader. 4. Wait for the StatementCompletedevent to fire, call the EndExecuteReadermethod, and then iterate through the DataReader.
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  How do you execute multiple SQL statements using a DataReader?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  When would you typically use an Input parameter? 1. When the parameter value is created based on user input 2. When the parameter is used to send data from the application to the database 3. When the command is set to execute a statement with a WHERE clause 4. When the parameter value is passed to an INSERT statement
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  What are the three primary kinds of parameters?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  How do you determine the actual SQL data type of a SqlParameter (the type expected by the SQL Server)?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  Which of the following is true?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  If you are using the DataSet and you have to display the data in sorted order what will you do?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  In which Event you can set the value of a Theme?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  You need to initialize some variable only when the first user accesses the application. What should you do?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  Which of the following template supports by Repeater control?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  Which of the following works on client side?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  Which of the following works on server side?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  Application_Start event is available in which file?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  You have to log the data into database if your session times out. Which event you will use?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  Which of the following is true when referencing master page from content page?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  If you are using Webparts in your web page then which control is necessary?
Category: Computer Science MCQs,   Published by: T-Code Scripts
MCQs:  What component do you need to enable for a user to add new web parts?
Category: Computer Science MCQs,   Published by: T-Code Scripts