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

How to prevent a caption row in a ggc from expanding the group when a cell in that row receives focus

Thread ID:





53006 Dec 7,2006 05:10 AM UTC Dec 7,2006 05:33 AM UTC WinForms 1
Tags: Grouping
James Blibo
Asked On December 7, 2006 05:10 AM UTC

i have a ggc with one level of grouping; when i use the arror key and navigate to the caption row, the group expands if it is collapse.

How can i prevent this and only allow user to expand the group by click the plus/minus button.

Administrator [Syncfusion]
Replied On December 7, 2006 05:33 AM UTC

Hi James,

You can handle TableControlCellButtonClicked event to set the IsClickExpand flag( sClickExpand = true;) and check this falg to expand the group in the GroupExpanding event of the grid. Here is a code snippet to show this.

bool IsClickExpand = false;
private void gridGroupingControl1_TableControlCellButtonClicked(object sender, GridTableControlCellButtonClickedEventArgs e)
GridTableCellStyleInfo style = e.TableControl.Model[e.Inner.RowIndex,e.Inner.ColIndex] as GridTableCellStyleInfo;
if( style.TableCellIdentity.TableCellType == GridTableCellType.GroupCaptionPlusMinusCell)
IsClickExpand = true;

private void gridGroupingControl1_GroupExpanding(object sender, GroupEventArgs e)
IsClickExpand = false;
e.Cancel = true;

Best Regards,

Best Regards,


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

or the page will be automatically redirected to 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