首先引用
Win Form中限制TextBox只能输入数字using System.Text.RegularExpressions;
给TextBox添加KeyPress事件,代码如下:
Win Form中限制TextBox只能输入数字private void textBox1_KeyPress(object sender, KeyPressEventArgs e)
        }

相关文章:

  • 2022-12-23
  • 2021-12-12
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-06-06
  • 2022-12-23
  • 2022-12-23
  • 2021-09-26
  • 2021-11-22
相关资源
相似解决方案