Conclusion

Conclusion

As you now see, ADO.NET is very different from the classic ADO we have been used to. The BindingContext object of a form manages the various CurrencyManager objects used to bind a table, a collection, or an array to a visual control. The BindingContext object ensures each of the individual CurrencyManager objects are synchronized when a new record is selected. To navigate through records, we manipulate the Position property of the BindingContext object. To bind a control to a column in a table, we simply add the table and field to the DataBindings collection of the individual control. Using this new knowledge, we learned how to navigate through a data table.

We also learned how to dynamically build a data table. Our example included building new columns and specifying their properties, such as the data type it will hold and its name. Next we went on to add data to our new table on the fly and then learned how to find individual records that contained specific values. These are all the things that we are used to doing with classic ADO, but you will no doubt agree that the way we approach the tasks in ADO.NET is very different.

This chapter wraps up our discussion of ADO.NET. You are now armed with the knowledge of accessing any data store. There were several new concepts we covered in the past three chapters—not the least of which is the disconnected nature of ADO.NET. As you think about this new paradigm, you will no doubt see how you can use this knowledge in new and previously unthought-of ways. Learning about Visual Basic .NET gives you all sorts of new perspectives on manipulating data.



Coding Techniques for Microsoft Visual Basic. NET
Coding Techniques for Microsoft Visual Basic .NET
ISBN: 0735612544
EAN: 2147483647
Year: 2002
Pages: 123
Authors: John Connell

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net