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.

GGC and SelectedRecord/ GridRecord

Thread ID:

Created:

Updated:

Platform:

Replies:

41792 Mar 11,2006 11:35 AM Mar 13,2006 05:00 AM Windows Forms 1
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On March 11, 2006 11:35 AM

Hi! I have a GGC and set the DataSource to DataView. After moving the CurrentCell, I get the selected data via ggc.Table.GetInnerMostCurrentElement(). No I set a new DataView as the DataSource. Visual there is still a row selected. But I can''t get the row! Neither via GetInnerMostCurrentElement() (==null) nor via ggc.Table.SelectedRecords (.Count==0). How can I get the selected GridRecord??? It seems there is no Record selected. Greetings Falk

Administrator [Syncfusion]
Replied On March 13, 2006 05:00 AM

Hi Falk, This can be achieved by moving the currentcell to the selected cell after changing the datasource. This happens, because the focus is lost as there is a change in the datasource. Here is the code snippet GridCurrentCell cc = this.gridGroupingControl1.TableControl.CurrentCell; int row = cc.RowIndex; int col = cc.ColIndex; this.gridGroupingControl1.DataSource = dt2; this.gridGroupingControl1.TableControl.CurrentCell.MoveTo(row,col); Regards, Madhan.

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.

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.

;