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

TableControlCellClick

Thread ID:

Created:

Updated:

Platform:

Replies:

58097 Mar 18,2007 12:59 PM UTC Mar 19,2007 03:53 PM UTC WinForms 1
loading
Tags: GridControl
NIBBLER
Asked On March 18, 2007 12:59 PM UTC

Hi.
I have a problem.

I'm using Syncfusion Essential GridGroupingControl 4.4.0.51. under .Net Framework 2.0 and encountered a problem with ContextMenu.
When it appears, it is bound to the previously selected cell, i.e., if cell [4,2] was active & I hover mouse over cell [5,6] and right-click, all functions are associated with cell [4,2].
How can I make a cell selected or active before the context menu appears or somehow fix this problem?


Administrator [Syncfusion]
Replied On March 19, 2007 03:53 PM UTC

Hi NIBBLER,

You can handle the TableControlMouseDown event of the grid and move the current cell to required position in a grid. Here is a code snippet

private void gridGroupingControl1_TableControlMouseDown(object sender, GridTableControlMouseEventArgs e)
{
int row,col;
e.TableControl.PointToRowCol(new Point(e.Inner.X,e.Inner.Y),out row,out col);
if( row != -1 || col != -1)
e.TableControl.CurrentCell.MoveTo(row,col,GridSetCurrentCellOptions.SetFocus);
}

Best regards,
Haneef

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

;