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.

constraints

Thread ID:

Created:

Updated:

Platform:

Replies:

66454 Jul 30,2007 06:14 AM Jul 30,2007 11:43 AM Windows Forms 1
loading
Tags: GridControl
John
Asked On July 30, 2007 06:14 AM


Hi,

I created a constraint on my table in sql by using:

ALTER TABLE myTable ADD CONSTRAINT Constraint1 CHECK (myColumn > 100);

Is there some way to get the databoundgrid to recognize this constraint on the table and warn the user if they enter in a number less than 100? I noticed that the grid by default will warn the user if they enter in a value that is too long for the maximum length allowed by a column. Is there something similar for check constraint on a table?

Thanks!



haneefm [Syncfusion]
Replied On July 30, 2007 11:43 AM

Hi Code123,

This ConstraintException has to be handled by the underlying datasource of the grid(ie DataSet/DataTable). Grid does not raise any events for this. If you want to validate the Check Constraint, you need to handle the validating events of the grid. Please refer to the below KnowledgeBase article for more details.

What are the different validation events and event members? When are they triggered and how are they used?

Best Regards,
Haneef

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.

;