views:

1668

answers:

1

Hi, I am beginner and I have this problem. How can I can update dataset with datagridview? I binding dataset in datagrid. Edit datagrid. At finish I want update dataset with datagridview. Thank you form any advice

Sory, I use Winforms.

Example: I bind dataset in datagridview.

 dataGridViewCustomers.DataSource =
_ds.Tables[0];

 //edit datagridview

 //on this place I want update dataset with datagrid view
A: 

Use this code

this.Validate();
this.yourBindingSource.EndEdit();
this.yourtableAdapterManager.UpdateAll(this.yourDataSet);

I hope this what you need.

salhzmzm
I am confuse, any example with SqlDataAdapter. How can I use TableManager?
Paul