Chapter 2. Using Connections

After completing this chapter, you will be able to:

  • Add an instance of a Connection to a Windows Form.

  • Create a Connection using code.

  • Use Connection properties.

  • Use an intermediary variable to reference multiple types of Connections.

  • Bind Connection properties to form controls.

  • Open and close Connections.

  • Respond to a Connection.StateChange event.

In this chapter, we'll begin our detailed examination of the Microsoft ADO.NET object model with the object at the lowest level, the Connection.

Understanding Connections

Connections are responsible for handling the physical communication between a data store and a .NET application. The Connection object is part of a Data Provider, and each Data Provider implements its own version. ...

Get Microsoft® ADO.NET 2.0 Step by Step, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.