Datagridview cellvalidating old value dating a 21 year old
Or if not, then it is because the user has entered an invalid value in the current cell.
provides a convenient way to realize data validation before it is committed to the underlying data source.
Hi there, I have a question regarding datagridview, I add data to the datagridview in an interface and all the validation for the datagridview cell is in the datagridview cell validating event for the datagridview.
I display the data of the is datagridview in another interface and make the cells read-only. But the thing is when I click on a row that data was added previously and press the Add new row the cell validating event is triggered.
However, pressing the Esc key in this situation will revert the initial value of the cell and it will close the editor. The Row Validating event has a slightly different behavior.
When the validation fails, the editor is closed, but the user cannot change the current row in the grid until a valid cell value is entered.