我正在使用DATAGIDVIEW控件,在此网格用户可以编辑固定列的值。
我希望用户只能写数字值(例如1, 2, 443等)。
我不确定在哪个datagridview事件中必须编写此代码,以及捕获值的代码是什么
最佳答案
检查这些物品:
Walkthrough: Validating Data in the Windows Forms DataGridView Control
How to: Validate Data in the Windows Forms DataGridView Control
Walkthrough: Handling Errors that Occur During Data Entry in the Windows Forms DataGridView Control
Working with the DataGridView Control
关于c# - Datagridview控件单元中的数据验证,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2935058/