unobtrusive validation

4 posts, 0 answers
  1. comgiu
    comgiu avatar
    29 posts
    Member since:
    Jun 2011

    Posted 28 Sep 2012 Link to this post

    HI,
    I've write this
    but for kendo control doesn't wok why?

    @(Html.Kendo().NumericTextBoxFor(m => m.size)
                                  .Min(1)
                                  .Decimals(0)
                                  .Format("{0:D}")
                                  .Spinners(false)
                    )
                    @Html.ValidationMessageFor(m => m.size)

    thanks
  2. Petur Subev
    Admin
    Petur Subev avatar
    1882 posts

    Posted 03 Oct 2012 Link to this post

    Hello Giuliano,

    Basically if you have added the input element inside a form element and you have included the needed scripts:
    jquery.validate.js
    jquery.validate.unobtrusive.js"

    And you have enabled the MVC options for client side validation:
    @Html.EnableClientValidation()
    @Html.EnableUnobtrusiveJavaScript()


    Just as shown here



    All the best,
    Petur Subev
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. UI for ASP.NET MVC is VS 2017 Ready
  4. Kevin Warnke
    Kevin Warnke avatar
    98 posts
    Member since:
    Dec 2005

    Posted 27 Jul 2013 Link to this post

    Petur-

    I'm using the Q2 2013 version of Kendo UI for ASP.NET MVC.  I created a brand new project from the Kendo template.

    However, when I add the reference to the jQuery.validate and jQuery.validate.unobtrusive scripts, when it tries to perform the client side validation, I get a javascript error in IE 10.  It seems to work okay in Chrome and FireFox.

    Is there a set of 1.. 2.. 3.. steps somewhere that shows us how to set up ASP.MVC client side validation to work while using Kendo UI?

    Thanks,
    Kevin
  5. Petur Subev
    Admin
    Petur Subev avatar
    1882 posts

    Posted 31 Jul 2013 Link to this post

    Hello,

    No we do not have tutorials how to include third party libraries such as jQuery validate. I can suggest you to check the Kendo validator which is part of the Kendo framework.

    http://docs.kendoui.com/getting-started/framework/validator/overview

    http://demos.kendoui.com/web/validator/index.html

    Kind Regards,
    Petur Subev
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Back to Top
UI for ASP.NET MVC is VS 2017 Ready