可以用MultiRow上的EditingControlShowing事件
- this.gcMultiRow1.EditingControlShowing += new System.EventHandler<GrapeCity.Win.MultiRow.EditingControlShowingEventArgs>(this.gcMultiRow1_EditingControlShowing);
-
- private void gcMultiRow1_EditingControlShowing(object sender, GrapeCity.Win.MultiRow.EditingControlShowingEventArgs e)
- {​​​​​​​
- // remove old event handler
- e.Control.KeyDown -= this.PrintKeyKode;
- // add new event
- e.Control.KeyDown += this.PrintKeyKode;
- }​​​​​​​
- private void PrintKeyKode(object sender,KeyEventArgs args)
- {​​​​​​​
- Debug.WriteLine(args.KeyCode);
- }​​​​​​​
复制代码 |