Datagrid cellvalidating event

Also this approach allows the user more flexibility.

Lets say the user its not required to enter data in all the rows of the datagridview, the latter approach would work just fine.

In the Cell End Edit event handler, set the Error Text property on the row to the empty string.

The Cell End Edit event occurs only when the cell exits edit mode, which it cannot do if it fails validation.

– Immediate validation: For those of you who have used dynamic regular expression validator in c#. However, one has to evaluate the pros and cons of each one.


How to efectively validate data entry inside a Data Grid View. Late Validation: This validation is performed after the user is done entering data.

Well, after doing some research and a bit of trial and error, found out a couple of approaches. For the specific project i was working in, it was the perfect choice.


  1. Pingback:

  2. eric   •  

    I’ve primarily used Uberhorny to accomplish this and you can do the same.

  3. eric   •  

    It is also claimed that the image is not a painting but a miraculously transposed image.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>