DatePicker remember previous date?

3 posts, 0 answers
  1. Sanjeev
    Sanjeev avatar
    5 posts
    Member since:
    Jun 2015

    Posted 13 Jul 2015 Link to this post

    I have couple of DateTimePicker in my ASP.NET project. I am running into issue where DateTime picker keeps remembering old selected date in my MVC page.


    1) Choose any future date from DateTimePicker control. e.g. 1/1/2020

    2) Clear the date in the Textbox so that there is no date value.

    3) Now, try clicking on DateTimePicker control, it will show 1/1/2020 instead of present date.


    Does anyone know how to reset the date to current date once the DatePicker textbox is cleared?


  2. Georgi Krustev
    Georgi Krustev avatar
    3688 posts

    Posted 15 Jul 2015 Link to this post

    Hello Sanjeev,

    The DatePicker widget is designed to clear the selected date in the calendar once the textbox is cleared, but it will not move the calendar to present date. This behavior is intended.

    If you would like to navigate the calendar to a specific date, then you will need to do that manually:
    Georgi Krustev
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Sanjeev
    Sanjeev avatar
    5 posts
    Member since:
    Jun 2015

    Posted 15 Jul 2015 in reply to Georgi Krustev Link to this post

    Thank you that worked!!
Back to Top