web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Beginner help please. ...
Power Automate
Unanswered

Beginner help please. Create all day event from Sharepoint list items.

(0) ShareShare
ReportReport
Posted on by 25

I am a beginner and can most often find an answer reading here to make a flow work, but I've been unsuccessful finding an answer. 

I am creating a flow that triggers when a new Sharepoint list item is created. 

An ALL DAY EVENT should be created for every new DATE FIELD ENTRY.

During testing I have tried setting my SHAREPOINT LIST DATE FIELD to include only the DATE (which always creates the event at 12:00 am). I've tried setting the LIST FIELD to DATE AND TIME (no matter what time I select, it still creates the event at 12:00 am. I'm guessing because I used the convert time zone function?)

In order to get the flow to run, I had to use CONVERT TIME ZONE . . Is there a way to make the output start time 12:00 am and end time 11:59 p.m. so it sees it as an all day event (if that would work)? Or some other work around? I found this solution, but I'm not quite sure how to write the expression to add 23 hours and 59 minutes, to my end time. I don't know if it will work, but seems like a logical solution????? 

In CREATE EVENT, if I select "Is all day event" the flow fails (see run details error when all day event is set to "yes")

Any help would be greatly appreciated!

Step 1.pngStep 2.pngStep 3.png

 

 

 

 

 

 

 

 

 

detail.png

 

Categories:
I have the same question (0)
  • DJ_Jamba Profile Picture
    2,837 Super User 2025 Season 2 on at

    It's my understanding that to mark an even as an "all day event", it must be a minimum of 24 hours, so I don't think creating an event for 23 hours and 59 mins will work (maybe someone else know different!).

    Option 1:

    Try creating an EndDate compose action before you create the event which adds 1 day to the start date:

    DJ_Jamba_0-1709476999957.png


    OR: addDays(YOUR_START_DATE,1)

    Put that compose action into the end date field then set All day event to Yes

    Option 2:
    Don't create an all day event. Just end the event at 23:59:59 on the same day:

    addToTime(addToTime(YOUR_START_DATE,1,'Day','yyyy-MM-dd'),-1,'Second')

    OR: addSeconds(addDays(YOUR_START_DATE,1,'yyyy-MM-dd'),-1)


    Then put that action in your end date and set All day event to No. You should have an event ending at 23:59:59 on the same day

  • CU30072308-0 Profile Picture
    25 on at

    Thank you! I got it to create an all day event, but..... it created the event one day prior to the start day. Did I type the expression correctly?

     

    test1.png

  • DJ_Jamba Profile Picture
    2,837 Super User 2025 Season 2 on at

    I think you are adding 1 day to the trigger start date but it looks like you are using a convert timezone action for the start date. You need to add 1 day to the converted timezone action start date instead

  • CU30072308-0 Profile Picture
    25 on at

    I changed it, but it is still creating the All Day Event for the day prior to the start date. Did I do it correctly?

    test3.png

     

  • DJ_Jamba Profile Picture
    2,837 Super User 2025 Season 2 on at

    I think it may still be converting back to UTC so let's try it this way.
    Rename your convert timezone action to Convert timezone action - StartDate

    Copy that action and rename the new one to Convert timezone action - EndDate

    The base time in Convert timezone action - EndDate should be the following formula:
    addToTime(triggerOutputs()?['body/ContractDate'],1,'Day')

    Then, I'm sure you'll know what to put in your start and end date fields in the Create Event action... 

  • DJ_Jamba Profile Picture
    2,837 Super User 2025 Season 2 on at

    I have just noticed something else.
    You are already converting the timezone in Create Event (I missed that sorry).
    If my latest suggestion doesn't work: 
    Keep start and end dates in UTC by simply creating a compose with your start date straight from triggerBody
    Then add another compose to add 1 day to the compose above.
    Don't convert timezone.
    Put the UTC start and end date compose values in the create event and set the timezone as you have been doing to Central time

  • Verified answer
    CU30072308-0 Profile Picture
    25 on at

    Thanks for your help! Option 2 worked. Here's a screen shot for anyone else that may have the same issue. 

    All day eventAll day event

  • DJ_Jamba Profile Picture
    2,837 Super User 2025 Season 2 on at

    You're welcome! 
    d(-_-)b

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard