Solved: SharePoint custom list calendar view End Date problem

Copper Contributor

Use Case:

You need a calendar view for a custom list which has a Start Date and End Date . For example: events, training, travel, bookings, etc.

Problem:

You will face this peculiar problem. If you have set the column as Date Only, the End Date automatically takes its time as 12:00:00 am internally. As a result, the calendar visual shows event ending on previous date. So, if your event starts 01-Feb-2019 and ends 05-Feb-2019, on the calendar it will render the event end as 04-Feb-2019.

Solution:

To fix this, (assuming end date column name is called End Date) create a calculated column called Actual_End (Format: Date&Time) with formula as:

=[End Date]+"6:00:00PM"

... the "Time" can be anything on the actual event end date other than 12:00 am. Modify the calendar view and set this calculated column as the End: in Time Interval section. Obviously, you can name your columns whatever you want.

After struggling for long, I finally arrived at this solution, hope this helps.  Do reply if there are other means to address this issue.

 

5 Replies

Hi @Yatin Purohit 

 

We are also having the same issue on our calendars. Would it not be simpler to change the column setting from "date only" to "date and time"? And then, when the user creates an event, they can add a time of 6:00:00PM in that field going forward. Or would changing the column settings disrupt the data in legacy events?

Yes, you are right. Creating a date and time column type will solve this too. However, in scenario where user is required to only enter date and not time, user interface will be confusing or irritating.
In my scenario, users block training rooms, very often across days. The requirement (also users habit) is to only enter booking dates and not time.

@Yatin Purohit 

 

But what if I change the settings on the current column? In other words, I don't create a new column I just change the settings on the existing column. My fear is, doing this, it will mess up past data. We can enforce entering the time, so that's not a problem. 

Absolutely changing current column type will work. Bear in mind that previous entries may have time as 00:00:00 and that may have impact on calendar display. . Possibly use a Power Automate flow to populated the time.

@Yatin

 

Excellent, thanks so much for the advice!