We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

validation: Required cell value

Thread ID:





101155 Sep 29,2011 04:39 PM UTC Oct 6,2011 04:44 AM UTC WinForms 1
Tags: GridControl
Asked On September 29, 2011 04:39 PM UTC

Is there a way we can specify validation on Grid Cell to make it required. (whether it is a string, datetime, currency etc)

Appreciate response.


Asarudheen S [Syncfusion]
Replied On October 6, 2011 04:44 AM UTC

Hi Ram,

Thank you for you interest in Syncfusion products.

You can validate a cell using by using “CurrentCellValidating” event. Please make use of following code to achieve the behavior.

void gridControl1_CurrentCellValidating(object sender, CancelEventArgs e)
if (this.gridControl1.CurrentCell.Renderer is GridTextBoxCellRenderer)
GridTextBoxCellRenderer ren = this.gridControl1.CurrentCell.Renderer as GridTextBoxCellRenderer;
if (ren.TextBox.Text == "Software")
e.Cancel = true;


Here is the sample for your reference.


Please let us know if you need any further assistance.



This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon