private void edtDoubleValue_KeyDown(object sender, KeyEventArgs e) { bool isNum = char.IsNumber((char) e.KeyCode); e.SuppressKeyPress = !isNum; }