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. Image for the cookie policy date

GGC: Do Not Focus Current Cell

Hi,

I have an issue with the GGC always scrolling to the current cell when it comes into focus. How can I make it so that the GGC does not scroll to the current cell when I leave the control and come back. This is useful as the GGC updates frequently with new records sorted by time, so the newest entries are on top. But if it always scolls to the current cell, you will always miss the new records being added. Thanks for you help.


1 Reply

AD Administrator Syncfusion Team April 17, 2008 03:13 PM UTC

Hi Patrick,

Thanks for the interest in Syncfusion products.

You can set the CurrentCell.MoveTo to a particular record when you add a new record. Please refer the following code snippet that shows how we can set CurrentCell.MoveTo.


private void button1_Click(object sender, EventArgs e)
{
dt.Rows.Add(new object[] { 212, "Mike" });
this.gridGroupingControl1.Refresh();
this.gridGroupingControl1.TableControl.CurrentCell.MoveTo(4, 1, GridSetCurrentCellOptions.SetFocus);
this.gridGroupingControl1.Focus();
this.gridGroupingControl1.TableControl.CurrentCell.BeginEdit();
}


Please refer the sample in the below link that illustrates the above.

http://websamples.syncfusion.com/samples/Grid.Windows/F72854/main.htm

If I have misunderstood your requirement, could you please explain me in detail, so that I can work in
depth and try to send a better solution?

Regards,
Asem.


Loader.
Live Chat Icon For mobile
Up arrow icon