By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,750 Members | 1,456 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,750 IT Pros & Developers. It's quick & easy.

DataGrid with a table style does not refresh properly when changing the datasource

P: n/a
I have a Windows form where a user enters an order number which returns a
dataset that is bound to a datagrid. The problem is when a user clicks on a
cell in the datagrid, then enters another order to get information for,
everything is updated with the new data except the cell in the grid that was
selected. This behavior does not occur when a table style is not applied to
the datagrid.

How do I refresh the datagrid so that the cell in the datadrid is also
refreshed?

Thanks,

Shawn
Nov 17 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
For those that may run into this, problem there is a KB article for this
problem:

890211 FIX: The cells are not cleared when you set the Datasource property
to NULL on cells that have a custom DataGridColumnStyle property in the
...NET Framework 1.1

http://support.microsoft.com/?id=890211

I also found that if the focus is set to the datagrid before changing the
datasource, it will refresh properly.

"Shawn Benson" <Sh****@nepopt.com> wrote in message
news:e3**************@TK2MSFTNGP14.phx.gbl...
I have a Windows form where a user enters an order number which returns a
dataset that is bound to a datagrid. The problem is when a user clicks on a cell in the datagrid, then enters another order to get information for,
everything is updated with the new data except the cell in the grid that was selected. This behavior does not occur when a table style is not applied to the datagrid.

How do I refresh the datagrid so that the cell in the datadrid is also
refreshed?

Thanks,

Shawn

Nov 17 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.