Wrong date format

6 posts, 0 answers
  1. Mario Turcotte
    Mario Turcotte avatar
    5 posts
    Member since:
    Dec 2008

    Posted 30 Sep 2009 Link to this post

    Hello all, first I am sorry if that question has already been asked and answered. If this is the case I would be grateful if someone can point me to the answer. Due to my work slow connection it take more then 2 minutes to get a page loaded and searching through is not an option at the moment.

    Here is my problem, I have two radDateTimePicker, one for Starting Date and one for Ending Date. I have set the DateInput format as follow.

    <telerik:RadDateTimePicker ID="rdtp_StartingDate" runat="server">                                                  
        <DateInput DateFormat="dd/MM/yyyy hh:mm tt" DisplayDateFormat="dd/MM/yyyy hh:mm tt" runat="server"></DateInput> 
        <Calendar DayCellToolTipFormat="dd/MM/yyyy" runat="server"></Calendar> 
    </telerik:RadDateTimePicker> 
     

    The culture of the two calendars is set from the codebehind, since the application I'm supporting, support two language.

    When I retrieve the values from the database, the date input format is displayed correctly. When I click on the Calendar image to get the Calendar popup, I mouse over the dates and the tooltip is fine to. The problem arise when I click on a date, if the day I select is smaller then 12 it switch the format to default. i.e. selecting first of june will display "06/01/2009 12:00 AM" instead of "01/06/2009 12:00 AM" if I pick 21st of june it will display "21/06/2009 12:00 AM" which is the correct format.

    Thank you in advance.
  2. Martin
    Admin
    Martin avatar
    833 posts

    Posted 06 Oct 2009 Link to this post

    Hello Mario,

    I tried to reproduce the issue but without success. Based on your code I am attaching a sample project that runs as expected on my side.

    I hope this helps

    Regards,
    Martin
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. Mario
    Mario avatar
    3 posts
    Member since:
    Dec 2008

    Posted 14 Oct 2009 Link to this post

    Hello Martin, thanks for your quick response.

    I found that this will happen when you set the calendar input to read only. For some reason if the day picked is smaller then 12 it will switch day-month and the next time you open the calendar it will move to the wrong month.
  4. Martin
    Admin
    Martin avatar
    833 posts

    Posted 19 Oct 2009 Link to this post

    Hello Mario,

    I am attaching a modified version of the sample project reflecting the ReadOnly setting. However I am still unable to reproduce the issue on my end. Please give it a try and verify whether you still get the erroneous behavior. 

    Regards,
    Martin
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  5. Erwin
    Erwin avatar
    74 posts
    Member since:
    Apr 2009

    Posted 20 Apr 2010 Link to this post

    I have the same problem.

    I have tested your sample code but it does not work in my part.

    In your sample I tried to open the calendar pop-up then click  January 1,  2010.

    Then I open the calendar pop-up and click  January 8,  2010.

    When I click the calendar pop-up button, the calendar pops up then the selected date in the calendar is August 1 2010.

    I can't find a better solution of this.

    Attached are the Screen Shots of your sample code that i test.

    Please tell me if this is fixed in the lates release?

  6. Martin
    Admin
    Martin avatar
    833 posts

    Posted 20 Apr 2010 Link to this post

    Hello Erwin,

    I am afraid that I am still not able to reproduce the issue locally. Attached is the sample website equipped with the latest version of RadControls for ASP .NET AJAX (Q1 2010 SP1 trial). Please give it a try and let me know what your findings are.

    Regards,
    Martin
    the Telerik team

    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 Public Issue Tracking system and vote to affect the priority of the items.
Back to Top