Thankyou Clay, thats all I needed to get out of trouble.
>Here is one way you can get this to work for standard TextBox cells.
>
>In your menuhandler, only perform your action if there is not a currently editing cell. Then also handle the CurrentCellControlKeyMessage event, and in that event, handle the delete key for the editing currentcell yourself.
>
>
>private void menuItem1_Click(object sender, EventArgs e)
>{
> if(!this.gridDataBoundGrid1.CurrentCell.IsEditing)
> {
> Console.WriteLine("menuItem1_Click");
> }
>}
>
>private void gridDataBoundGrid1_CurrentCellControlKeyMessage(object sender, GridCurrentCellControlKeyMessageEventArgs e)
>{
> Keys keyCode = (Keys)((int)e.Msg.WParam) & Keys.KeyCode;
> if(keyCode == Keys.Delete)
> {
> Console.WriteLine("gridDataBoundGrid1_CurrentCellControlKeyMessage");
> GridCurrentCell cc = this.gridDataBoundGrid1.CurrentCell;
> GridTextBoxControl tb = cc.Renderer.Control as GridTextBoxControl;
> if(tb != null)
> {
> if(tb.SelectionLength == 0)
> tb.SelectionLength = 1;
> tb.SelectedText = "";
> e.Handled = true;
> e.Result = true;
> }
> }
>}
>