Grid custom validation not shown

5 posts, 0 answers
  1. Scott Waye
    Scott Waye avatar
    129 posts
    Member since:
    Nov 2009

    Posted 07 Feb Link to this post

    Hi,

    http://dojo.telerik.com/IyoVU/6

    In this dojo, I'm trying to mix validation tooltips on simple fields, with custom validation on grid columns.  I've used your grid example which validates for the product name beginning with a capital.  Run the example, add a row to the grid, enter a product name that is invalid, e.g. "a" and tab off.  The product validation tooltip message is not shown, when I think it should be.  What am I doing wrong?

     

    Thanks,

     

    Scott

  2. Stefan
    Admin
    Stefan avatar
    416 posts

    Posted 09 Feb Link to this post

    Hello Scott,

    The message is not displayed because the Grid is in a form with a Validator which is conflicting with the Grid validation on a tab, as the validation message will still be displayed when clicking the update button.

    Please place the Grid outside of the form with the Validator and the custom validation set in the DataSource configuration will be triggered and displayed as expected.

    Let me know if you need additional information on this matter.

    Regards,
    Stefan
    Telerik by Progress
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
  3. Scott Waye
    Scott Waye avatar
    129 posts
    Member since:
    Nov 2009

    Posted 09 Feb in reply to Stefan Link to this post

    Stefan,

    If I understand you correctly then I cannot place grids inside forms where the form contains a validator. if I want the grid validation to work as expected, is that correct?  I'm not sure that is very easy.  On my tabs if I also want simple field validation in addition to the grid, how do I structure that, with a separate validator for each tab which covers the simple fields but not the grid?

  4. Scott Waye
    Scott Waye avatar
    129 posts
    Member since:
    Nov 2009

    Posted 09 Feb in reply to Scott Waye Link to this post

    Just realised there are no tabs in that dojo, can you clarify what you mean be "tab" in your response?
  5. Stefan
    Admin
    Stefan avatar
    416 posts

    Posted 10 Feb Link to this post

    Hello Scott,

    By tab I meant pressing the tab key which is usually used to change the edited field(also triggering the blur event).

    Still, the custom validation error popup will not be shown as it has a conflict with the form validator as both are called with validating on blur, that is why when the update button is clicked the validation is shown because it does not occur on blur.

    Apologies for the inconvenience this may cause you.

    Regards,
    Stefan
    Telerik by Progress
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top