O'Reilly logo

ADO.NET Programming in Visual Basic™ .NET by Bob Howell, Steve Holzner

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Programmatically Configuring a DataAdapter Using the CommandBuilder

Sometimes, you cannot know at design time exactly how your Data Adapter will be configured. The configuration might depend on user input or data in another table. You may want to use dynamic SQL where you build your statements at runtime instead of using replaceable parameters. This is especially useful in a query generator search screen where you do not know in advance what the user wants to search for.

Create a Windows Forms project called ADOBook06-02. (Or get it from the web site.) If you want to work along, use the starter project, otherwise you can just follow along. We’ll be using the same interface as the last project, so you can make a copy of it and delete the DataAdapter ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required