June 2003
Intermediate to advanced
624 pages
12h 41m
English
The ch10_01 example creates a connection to a data source, SQL Server in this case, and then binds the data from that data source to a data grid. This example uses the authors table in the pubs database, and displays that table, as you can see in Figure 10.2.

We'll take this example apart line by line to see what makes it tick. When the user clicks the Connect to Database button you see in Figure 10.2, this application starts by creating a new dataset object named dataset1, passing that name to the DataSet constructor (note that we're using the System.Data.SqlClient namespace here to ...