How to navigate in DataGrid

Hi, How can I move focus to cell to cell in a DataGrid using "Enter key" instead of "Tab key"?? Can anyone help. Thank thomas

1 Reply

CB Clay Burch Syncfusion Team July 2, 2002 08:29 AM UTC

One way you can do this is to use a derived DataGrid and override the ProcessCmdKey. In your override, catch the Enter key and use SendKeys to change it to a Tab key.
protected override bool ProcessCmdKey(ref System.Windows.Forms.Message msg, System.Windows.Forms.Keys keyData)
		{
			if(msg.WParam.ToInt32() == (int) Keys.Enter)
			{
				SendKeys.Send("{Tab}");
				return true;
			}
			return base.ProcessCmdKey(ref msg, keyData);
		}

Loader.
Up arrow icon