Using the Visual Studio.NET 2005 designer, I have a grid bound data a
DataBindingSource, no code was written, I just used the VS.NET provided
tools to set up three columns and I have the DataGridView acting by
default so I can delete rows and edit the contents of the grid.
To perform the update/comit to the database, I put a new button on the
form when it's clicked I call
dataGridView1.EndEdit(); this does not update the database.
Is there anything more I should be doing?
The database in this case is a Microsoft Access database. Using OleDb.
Bart Mermuys - 13 Nov 2006 19:45 GMT
Hi,
> Using the Visual Studio.NET 2005 designer, I have a grid bound data a
> DataBindingSource, no code was written, I just used the VS.NET provided
[quoted text clipped - 6 lines]
>
> Is there anything more I should be doing?
Validate();
yourBindingSource.EndEdit();
yourTableAdapter.Update(yourDataSet.yourDataTable);
If you use the Data Sources window ( Menu->Data->Show Data Sources ) and
then drag a DataSource on the Form it will create all required code.
HTH,
Greetings
> The database in this case is a Microsoft Access database. Using OleDb.