The Architecture of Data Binding

1. Create Connection Object. The connection that the users create, forms the basis for all other activities. In doing so the user creates a connect string and also a connection object that provides connection to the database.

2. Create DataSet and DataAdapter. Then the user proceeds to set the Data Binding property of the text box. At this stage the Visual Studio creates a DataSet and a DataAdaptor. The “Select ... “ statement for creating the DataSet is also autogenerated based on the selections the user has made in the Data Source configuration wizard.

3. Call the fill method of the DataAdapter to fill the dataset. This also adds a line of code that fills the dataset using the data adapter and the connection object . At the end of it all the data from the selected data source is available for the control when the form loads.

No comments: