标签:
private void txtSum_KeyPress(object sender, KeyPressEventArgs e)
{
if ((e.KeyChar != 8 && !char.IsDigit(e.KeyChar))&&e.KeyChar!=13)
{
MessageBox.Show("商品数量只能输入数字","操作提示",MessageBoxButtons.OK,MessageBoxIcon.Information);
e.Handled = true;
}
}
标签:
原文地址:http://www.cnblogs.com/haimingkaifa/p/5605799.html