C# Windows Form DataGrid and DataTable

J

Jason Huang

Hi,

I have a DataGrid DataGrid1 in my C# Windows Form MyForm.
The DataGrid1 uses DataTable as it's DataSource in the run time.
Now that I have Column1 and Column2 and 2 DataRows in MyDataTable.
How do I do to let the DataTable updated saying that I changed the
DataGrid1's value?
Thanks for help.


Jason
 
G

Guest

Actually with a bound Winforms DataGrid, if a user makes a change or adds a
row using the actual grid UI, I believe the underlying datasource is updated
as part of this process. if you need an event, look at the RowChanged and
similar events of the DataTable class
-- Peter
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top