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

How can i catch the tab key in KeyDown event of Grid control

Thread ID:

Created:

Updated:

Platform:

Replies:

35908 Oct 13,2005 12:44 PM UTC Oct 13,2005 01:22 PM UTC Windows Forms 2
loading
Tags: GridControl
Joshua
Asked On October 13, 2005 12:44 PM UTC

Any idea? I try all combination of WantKeys and WantTabKey but still have no luck.

Administrator [Syncfusion]
Replied On October 13, 2005 01:04 PM UTC

To catch the tab key, you can derive teh grid and override ProcessCmdKey.
public class MyGridDataBoundGrid : GridDataBoundGrid
{
	protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
	{
		if(keyData == Keys.Tab)
		{
			//tab key pressed		}
		return base.ProcessCmdKey (ref msg, keyData);
	}
}

Joshua
Replied On October 13, 2005 01:22 PM UTC

Thanks >To catch the tab key, you can derive teh grid and override ProcessCmdKey. >
>public class MyGridDataBoundGrid : GridDataBoundGrid
>{
>	protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
>	{
>		if(keyData == Keys.Tab)
>		{
>			//tab key pressed		}
>		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

;