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.
Unfortunately, activation email could not send to your email. Please try again.

Validation of controls

Thread ID:

Created:

Updated:

Platform:

Replies:

41725 Mar 9,2006 12:51 PM Mar 10,2006 02:27 AM Windows Forms 1
loading
Tags: GridControl
Hassan Hussein
Asked On March 9, 2006 12:51 PM

I have a GridControl. In the Grid columns there are several different controls NumericUpDown, MonthCalendar etc. Now, I expected that a NumericUpDown will not accept a non numeric value but it allows everything. I can also type "hello world!" into a MonthCalendar!!! It doesn''t make sense. Is there a way to make these controls self validate without code from my part (handling validation events)? Many thanks

Administrator [Syncfusion]
Replied On March 10, 2006 02:27 AM

Hi Hassan, For validating a numeric value cell the style.ValidateValue.NumberRequired property can be set to true and you can also set your own error message in the style.ValidateValue.ErrorMessage property. In order to validate a DateTime value cell the style.CellValueType can be set to typeof(System.DateTime). But this also throws the FormatException in the Output Debug window. Let us know if you have any further questions. Regards, Calvin.

CONFIRMATION

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.

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.

;