We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Refresh data

Thread ID:

Created:

Updated:

Platform:

Replies:

3598 Mar 29,2003 02:46 PM UTC Mar 30,2003 04:47 AM UTC Windows Forms 2
loading
Tags: GridControl
Peter
Asked On March 29, 2003 02:46 PM UTC

Sometimes I have to replace the data in the grid with other data (eg. the user changes the language in which he wanna see the data). So I clear the datatable and dispose the dataadapter. Then I create a new dataadapter and fill the datatable. After that I set the DataSource of the grid to the DataTable. Although there are rows in the DataTable the Grid doesn't show them. Is there a better way to replace the data in the grid or why the described behaviour occurs?

Peter
Replied On March 30, 2003 04:41 AM UTC

In additition to this I wanna refresh the data in da DataBoundGrid every time a user selects another row. In the RowEnter event I do a DataTable.Clear and then a fill from the dataadapter. After that I set the DataSource of the Grid again to the DataTable. All works fine if the default sorting is used. If the user resorts the Grid by clicking at the column header it works all too but there is a flickering in the Grid where you can see that all cells are removed and then refilled. I thought of preventing this by add a "BeginUpdate" and "EndUpdate" around the code but that doesn't help. What am I doing wrong?

Peter
Replied On March 30, 2003 04:47 AM UTC

Well if you write the problems down and think about them a while you solve them at your own :-) I found out that all problems are solved with putting a "GridDataBoundGrid.Binder.SuspendBinding" and "GridDataBoundGrid.Binder.ResumeBinding" around.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;