Datepicker Saving Format Issue

4 posts, 0 answers
  1. Adhip
    Adhip avatar
    4 posts
    Member since:
    Aug 2016

    Posted 21 Sep Link to this post

    Hi,

    I am using a date picker to edit the date displayed on my grid.

    @(Html.Kendo().DatePicker()
                     .Name("Date")
                     .Value("Value")
                     .Format("MM/dd/yyyy")
                     .HtmlAttributes(new { style = "width: 30%" })
    )
    The problem is while saving the date it gets saved as shown in the attachment.

    I just want it to be saved in the format (mm/dd/yyyy) and I dont want those extra labels such as indian standard time etc.

    Can anyone help?

    Regards,

    Adhip

     

  2. Eduardo Serra
    Admin
    Eduardo Serra avatar
    51 posts

    Posted 21 Sep Link to this post

    Hello Adhip,

    What you're describing is not an issue related to the Kendo UI Datepicker; the format you're seeing is the default string output format for JavaScript Date objects. If you want to save the date as a string with a different format, then feel free to manipulate the date object beforehand.

    I hope this helps!

    Regards,
    Eduardo Serra
    Telerik by Progress
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for ASP.NET MVC is VS 2017 Ready
  4. Adhip
    Adhip avatar
    4 posts
    Member since:
    Aug 2016

    Posted 21 Sep in reply to Eduardo Serra Link to this post

    Hi Eduardo,

    Thanks for your reply, I will look into it.

    Also what you said can be applied to the Timepicker as well because it is also saving the time in a similar format?

     

    Thanks and Regards,

    Adhip

  5. Eduardo Serra
    Admin
    Eduardo Serra avatar
    51 posts

    Posted 22 Sep Link to this post

    Hello Adhip,

    Yes, it can also be applied to the TimePicker!

    Regards,
    Eduardo Serra
    Telerik by Progress
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top
UI for ASP.NET MVC is VS 2017 Ready