If I have a cell in a grid, and that cell is active to the point where I have selected text, and I right click on my mouse, I do not get the context menu. So I tried to get the mouse event to force the display of the menu, but in this scenario, I am not getting the _MouseDown or _OnCellMouseDown events. Is this by design?
ADAdministrator Syncfusion Team November 20, 2003 04:35 PM UTC
This is by design. When an actively editing cell gets clicked, it is not the grid that get the click, but is the active cell control that gets the click.
Here is a sample that I think will catch both cases, the grid getting the click and the cell control getting the click. It uses the grid_MouseUp event to handle all right clicks that the grid catches (which include the checkbox case), and dynamically hooks the cellcontrol_MouseUp in CurrentCellControlGotFocus and unhooks it in CurrentCellControlLostFocus to catch the active cell control's clicks.