Kendo Date Picker Date disappears in Chrome

5 posts, 0 answers
  1. Raja
    Raja avatar
    47 posts
    Member since:
    Oct 2013

    Posted 17 Mar Link to this post

    Hi,

    I have a datepicker on a page which was working perfectly until yesterday. Suddenly it stopped showing existing dates in Chrome. if I select new date from the picker it works fine. I get a javascript error in the browser. I have posted similar questions with javascript error couple of years back. http://www.telerik.com/forums/date-format-error-with-date-picker 

    It was resolved at that time using the Format.

    @(Html.Kendo().DatePickerFor(m => m.BirthDate)
          .Name("BirthDate")
         .Value(Model.BirthDate)
         .Format("MM/dd/yyyy")
         .HtmlAttributes(new { @class = "form-control" }) )

    Now as per the suggestion in the above link, i have change the code like this

    @(Html.Kendo().DatePickerFor(m => m.BirthDate)
         .Name("BirthDate")
        .HtmlAttributes(new { type = "text" })
        .Value(Model.BirthDate)
        .Format("MM/dd/yyyy")
        .HtmlAttributes(new { @class = "form-control" }))

     

    But still no use. I still don't see the dates.

  2. Raja
    Raja avatar
    47 posts
    Member since:
    Oct 2013

    Posted 17 Mar in reply to Raja Link to this post

    I don't have an option to edit the above post. But here is the current code, I am not using Format with type.

     

    @(Html.Kendo().DatePickerFor(m => m.BirthDate)
         .Name("BirthDate")
        .HtmlAttributes(new { type = "text" })
        .Value(Model.BirthDate)
        .HtmlAttributes(new { @class = "form-control" }))
  3. Vasil
    Admin
    Vasil avatar
    1604 posts

    Posted 21 Mar Link to this post

    Hi,

    What is the JavaScript error that you get?

    Regards,
    Vasil
    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.
  4. Raja
    Raja avatar
    47 posts
    Member since:
    Oct 2013

    Posted 24 Mar in reply to Vasil Link to this post

    this is the error I am getting, just like the error that I used to get a while ago (same as the incident I referred in the original post)

    The specified value "07/06/1954" does not conform to the required format, "yyyy-MM-dd".
  5. Vasil
    Admin
    Vasil avatar
    1604 posts

    Posted 28 Mar Link to this post

    Hi Raja,

    The error message you see seems to be from the Chrome itself. And it should not appear if the input have "text" type or don't have any type.

    It does not seems to be an issue when I test it locally. Could you send us the output HTML of the page, as you see it in the browser?

    Regards,
    Vasil
    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