Start Updating datagrid asp net

Updating datagrid asp net

This method uses the Sql Data Adapter to populate a Data Set.

Now which method of calculating the totals in the screen child datagrid would you choose?

Rather than responding to each questioner individually, I decided to write this article explaining my rationale.

Read on to learn why I am a Data Reader man all the way. There are such things as strongly-typed Data Sets, which are classes that extend the Data Set (and Data Table) classes and include properties and other members specific to the data being represented by the Data Set.

Open() ' Create command Dim my Command as New Sql Command(SQL query or stored procedure, my Connection) ' Create a Data Reader to ferry information back from the database Dim my Reader as Sql Data Reader my Reader = my Command. End While ' Close the connection (will automatically close the reader) my Connection.

Execute Reader() 'Iterate through the results While my Reader. Close() method returns True if a row was loaded from the database, and False if there are no more rows.

Abstract: Data Grid View control is a Windows Forms control that gives you the ability to customize and edit tabular data.

It gives you number of properties, methods and events to customize its appearance and behavior.

While these types of Data Sets still suffer from the performance issues noted in this article, they are much preferred to loosely-typed Data Sets.