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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

lock a cell in GGC

Thread ID:





96639 Sep 23,2010 02:52 PM UTC Sep 24,2010 07:01 PM UTC WinForms 1
Tags: Grouping
Sai Pavan Kumar
Asked On September 23, 2010 02:52 PM UTC


If the user alters a cell in a GRID GROUPING CONTROL, then he has to click on any of the 4 buttons that i have in my UID.

If user alters and does not click on any of those buttons, he should not be able to move out of the cell.
Cursor has to get locked into that particular cell of GGC, unless he clicks any one of those 4 buttons.

Help me out..


Rajadurai C [Syncfusion]
Replied On September 24, 2010 07:01 PM UTC

Hi Pavan,

Thanks for your interest in Syncfusion Products.

To prevent a cell focus getting moved away after modifying the content until any of the buttons placed in UI is clicked, you can handle the TableControlCurrentCellMoving event with the following code.

// Event Handler
this.gridGroupingControl1.TableControlCurrentCellMoving += new Syncfusion.Windows.Forms.Grid.Grouping.GridTableControlCurrentCellMovingEventHandler(gridGroupingControl1_TableControlCurrentCellMoving);

// Method Invoked
void gridGroupingControl1_TableControlCurrentCellMoving(object sender, Syncfusion.Windows.Forms.Grid.Grouping.GridTableControlCurrentCellMovingEventArgs e)
if (e.TableControl.CurrentCell.IsModified)
e.Inner.Cancel = true;

As the button is placed in UI, the focus can be moved to button from the grid provided the CausesValidation property is set.



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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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