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.

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

Thread ID:

Created:

Updated:

Platform:

Replies:

35908 Oct 13,2005 08:44 AM Oct 13,2005 09:22 AM Windows Forms 2
loading
Tags: GridControl
Joshua
Asked On October 13, 2005 08:44 AM

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

Administrator [Syncfusion]
Replied On October 13, 2005 09:04 AM

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 09:22 AM

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.

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.

;