Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
186 | Apr 23,2002 04:12 AM UTC | Apr 29,2002 06:02 AM UTC | WinForms | 3 |
![]() |
Tags: FAQ |
public class MyDataGrid : DataGrid { const int WM_KEYDOWN = 0x100; public override bool PreProcessMessage( ref Message msg ) } Keys keyCode = (Keys)(int)msg.WParam & Keys.KeyCode; if(msg.Msg == WM_KEYDOWN && keyCode == Keys.Delete) { if(MessageBox.Show("Delete this row?", "", MessageBoxButtons.YesNo) == DialogResult.No) return true; } return base.PreProcessMessage(ref msg); } }
This post will be permanently deleted. Are you sure you want to continue?
Sorry, An error occured while processing your request. Please try again later.
This page will automatically be redirected to the sign-in page in 10 seconds.