I''ve got a popup menu defined with a delete bar item which has the shortcut set to Shortcut.Del
Unfortunately the click event for this bar item is firing when I hit the delete key while editing text in a cell in the grid (which is not at all desirable). How can I prevent this from occuring?
Is there any way in that override class to determine whether the grid has a Syncfusion XP context menu?
SHSue HarrisDecember 9, 2004 03:54 PM
Unfortunately the ProcessCmdKey doesn''t seem to trigger in the instance of the popup menu shortcut firing when editing. It only triggers in the reverse situation (when I''m not editing), so apparently its firing on the cell controls ProcessCmdKey (which I doubt I can override them all). Do you have any further ideas?
ADAdministrator Syncfusion Team December 9, 2004 06:32 PM
I tried it with a main menu item, and that worked OK for me.
I did not try it with a ContextMenu. Can you post a sample showing what you are doing?
As far as knowing what kind of menu is being used, are you usingteh grid.ContextMenu property? if so, you could text the typpe of that obejct.
SHSue HarrisDecember 9, 2004 08:36 PM
My apologies, I missed the piece of code in my base class that set the context menu of the renderer to the grids context menu. Commenting that line out fixed the problem.