set validation error on cell from outside grid

4 posts, 0 answers
  1. Jim
    Jim avatar
    68 posts
    Member since:
    Apr 2011

    Posted 17 Oct 2011 Link to this post

    In my CellValidating handler I can set my cell to show the red validation error with 

            e.IsValid = false;
            e.ErrorMessage = "OrderNO must be longer than five characters.";

    But is it possible to set this from outside the grid, i.e. when an async lookup returns some while later.
    Thanks
    Jim

  2. Jim
    Jim avatar
    68 posts
    Member since:
    Apr 2011

    Posted 19 Oct 2011 Link to this post

    I guess it's not possible!
    The only way I can get async validation to work is to use

    INotifyDataErrorInfo


    on the data objects.
    So I and add and remove erros from the object and this show on the grid.
    Jim
  3. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 19 Oct 2011 Link to this post

    Hello Jim,

    Indeed, you can work with INotifyDataErrorInfo. Please take a look at this blog post for a reference.
     

    Kind regards,
    Maya
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  4. Jim
    Jim avatar
    68 posts
    Member since:
    Apr 2011

    Posted 21 Oct 2011 Link to this post

    Yes it seems to work OK
    Thanks
    Jim
Back to Top