日期:2014-05-17 浏览次数:21184 次
void dataGridView1_EditingControlShowing(object sender, DataGridViewEditingControlShowingEventArgs e)
{
TextBox txtBox = e.Control as TextBox;
if (txtBox != null)
txtBox.KeyPress += txtBox_KeyPress;
}
void txtBox_KeyPress(object sender, KeyPressEventArgs e)
{
//这里判断事件
}