ProcessCmdKey question?

  • Thread starter Thread starter Trooper
  • Start date Start date
T

Trooper

Hi!

I need help with calling ProcessCmdKey. I'm little bit confused
how to use this method from my app. How to call it, from where?
Can somebody explain to me?

Thnx.

This is the source:

public class MyDataGrid : DataGrid
{
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);
}
}
 
Back
Top