Home › Forums › WinForms controls › Xceed Grid for WinForms › GridControl KeyDown event not raised on Tab › Reply To: GridControl KeyDown event not raised on Tab
If you really need this functionality (detect Tab-key), you can subclass the GridControl, and override the <b>IsInputKey</b> method, like this:<code>public class MyGridControl : GridControl
{
protected override bool IsInputKey(Keys k) {
if (k == Keys.Tab || k == (Keys.Shift | Keys.Tab)) return true;
else return base.IsInputKey(k);
}
}</code>If you use this class instead of GridControl, the <b>KeyDown</b> event will be fired when pressing Tab or Shift+Tab. Beware that the grid will also not give focus to the next control: focus will stay inside the grid.
Imported from legacy forums. Posted by Tommy (had 433 views)