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.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Capturing all cell keydown events

Thread ID:

Created:

Updated:

Platform:

Replies:

5451 Jul 3,2003 05:28 AM UTC Jul 3,2003 07:55 AM UTC Windows Forms 1
loading
Tags: GridControl
Martin
Asked On July 3, 2003 05:28 AM UTC

Hi I need to capture all keypresses that occur within a cell (so I can handle tab presses) The closest thing I've found is the CurrentCellKeyDown event, but this doesn't get fired when the cell is actually in edit mode. Is there any way to do this? Thanks Martin

Administrator [Syncfusion]
Replied On July 3, 2003 07:55 AM UTC

We are looking into the behavior of CurrentCellKeyDown right now. Not sure how what will be done will affect the tab key since that is a special key. In any case, if you want to catch all tab keys in the grid whether or not a cell is being edited, you can derive the grid and override ProcessCmdKey.
public class MyGridControl : GridControl
{
	protected override bool ProcessCmdKey(ref System.Windows.Forms.Message msg, System.Windows.Forms.Keys keyData)
	{
		if(keyData == Keys.Tab)
		{
			Console.WriteLine("Got a tab");
		}
		return base.ProcessCmdKey(ref msg, keyData);
	}
}

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

;