Updates the database wiht the changes made to the dataset. Remember to have had set the selectstring. One limitation is that you only can insert/update/delete the first table in the dataset due to the limitation of the object sql command builder.

[Visual Basic]
Overloads Protected Function Update( _
   ByVal updatedDataSet As System.Data.DataSet _
) As Integer
[C#]
protected int Update(
   DataSet updatedDataSet
);

Parameters

updatedDataSet

The dataset to update the database with

Return Value

The number of rows in the dataset affected by the update

Example

public int UpdateUserInfo(DataSet ds)
            {
            	SourceTable="tDocuments";
            	SelectString = "--The query you used to get the data-- ";
            
            	return  Update(ds);
            
            }

See Also

Adapter Class | Adapter Members | Magnusson.Data.SqlClient Namespace | Adapter.Update Overload List