locked
SharePoint Calendar date off by 1 RRS feed

  • Question

  • I have an InfoPath 2010 form that users put a start and end date into.  The form is submited to a SharePoint 2010 library with a calendar view.   The Time Interval of the calendar view is set to the Start and End Dates of the form.  That information is then presented in the Calendar view of the library. 

    My problem is that the dates are off in the calendar by one day.  Where a submited forms start/end dates might be 6/24 to 6/28 the calendar shows it as 6/24 to 6/27.  Off by one day.  I could create a custom field and add one to the end date, then use that as the Time Interval, but then that would add one to any single day request (i.e. 6/24 to 6/24 would become 6/24 to 6/25). 

    Can someone tell me why this is hapening and how to fix it? 

     


    Thanks in advance for your time. Steven
    Wednesday, June 29, 2011 4:14 PM

Answers

  • Hi smonczka,

    If you go to All Documents view and display Start Date and End Date field in that view, you will find that End Date filed will always get the date like this: 7/1/2011 12:00 AM. This is because if you use Date picker control in InfoPath to submit the date, it will only submit the date part, but End Date field is a Data & Time type, it will get 12:00 AM by default. So the dates in calendar view will always display as the End Date off by one day.

    I tested to add a calculated column with formula [End Date]+1, it works well in calendar view both Date or Date & Time type. So please recheck your custom field, ensure you have get current date, especially the time part.

    Best regards,
    Emir


    • Marked as answer by smonczka Monday, July 4, 2011 5:23 PM
    Friday, July 1, 2011 12:07 PM

All replies

  • Hi smonczka,

    If you go to All Documents view and display Start Date and End Date field in that view, you will find that End Date filed will always get the date like this: 7/1/2011 12:00 AM. This is because if you use Date picker control in InfoPath to submit the date, it will only submit the date part, but End Date field is a Data & Time type, it will get 12:00 AM by default. So the dates in calendar view will always display as the End Date off by one day.

    I tested to add a calculated column with formula [End Date]+1, it works well in calendar view both Date or Date & Time type. So please recheck your custom field, ensure you have get current date, especially the time part.

    Best regards,
    Emir


    • Marked as answer by smonczka Monday, July 4, 2011 5:23 PM
    Friday, July 1, 2011 12:07 PM
  • Emir thank you!
    Thanks in advance for your time. Steven
    Monday, July 4, 2011 5:23 PM
  • Thanks just tried this as well and works great!  Hopefully Microsoft fixes this in the future. 
    Monday, April 2, 2012 9:55 PM