Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
145
Only Validate IDataErrorInfo on Visible Rows in UltraGrid
posted

Is there a way to only validate IDataErrorInfo errors on visible rows on an UltraGrid? When I implement the Error property on a custom object that implements IDataErrorInfo, that property is getting called for every row in the grid when I mouse over the grid. This is fine for a grid with a few dozen rows, but when the grid contains several thousands rows, the grid is unusable. I've provided the implementation of the Error property below. Any ideas?

public virtual string Error

{
get
{
StringBuilder error = new StringBuilder();

var results = new List<ValidationResult>();

bool valid = Validator.TryValidateObject(this,
new ValidationContext(this, null, null),
results, true);

foreach (ValidationResult result in results)
{
error.AppendLine(result.ErrorMessage);
}

return error.ToString();
}
}

Parents
  • 2575
    Offline posted

    Hello, 

    After investigating IDataErrorInfo errors and doing some research, limiting to visible rows has been determined to be a new product idea. You can suggest new product ideas for future versions (or vote for existing ones) at <http://ideas.infragistics.com>.

    Submitting your idea will allow you to communicate directly with our product management team, track the progress of your idea at any time, see how many votes it got, read comments from other developers in the community, and see if someone from the product team has additional questions for you.

    Remember when submitting your idea to explain the context in which a feature would be used and why it is needed as well as anything that would prevent you from accomplishing this today. You can even add screenshots to build a stronger case. Remember that for your suggestion to be successful, you need other members of the community to vote for it.  You can also link back to this thread for additional details.

    Thank you in advance to submitting your product idea.

Reply Children