Answers

Question and Answer:

  Home  MCSD.NET - 70-306 Exam

⟩ Suppose You develop a Windows-based application XYZiApp by using Visual Studio .NET. XYZiApp usesa SqlConnection object for database access.You typically run XYZiApp on a computer that has limited RAM and hard disk space. After thecode finishes using the SqlConnection object, you must ensure that the connection is closed andthat any resources consumed by the object are released immediately.What should you do?A. Call the Finalize method of the SqlConnection object.B. Call the Dispose method of the SqlConnection object.C. Set the SqlConnection object equal to Nothing.D. Set the SqlConnection object equal to

B. Call the Dispose method of the SqlConnection object.

 190 views

More Questions for you: