cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
BHS_KI
Helper II
Helper II

Office365-Groups Connector: CreateCalendarEventV2 Problem

BHS_KI_0-1668246652495.png

Hi there I am struggling with the syntax of the CreateCalendarEventV2. I made a simple test, but does not work. Seemed to be different to the personal calendar. 

 

Someone who can help me, please?

 

Thanks,

Klaus

9 REPLIES 9
StalinPonnusamy
Super User
Super User

Hi @BHS_KI 

 

Please try this.

 

Office365Groups.CreateCalendarEventV2(
    "04970c65-7023-46a2-ba39-eed515a9256a",
    "New Client Project Meeting",
    {
        dateTime: Now(),
        timeZone: UTC
    },
    {
        dateTime: DateAdd(
            Today(),
            2
        ),
        timeZone: UTC
    },
    {
        body: {
            content: "New Project",
            contentType: "Text"
        },
        location: {displayName: "Client Meeting"},
        importance: "Normal",
        isAllDay: false,
        isReminderOn: false,
        showAs: "Busy",
        responseRequested: false
    }
)

 

 


Thanks, Stalin (Microsoft MVP)
Blog - Learn To Illuminate Blog
YouTube - Learn To Illuminate Videos

Hi @BHS_KI 

 

We can also use the Office365 Outlook connector to create appointments.

 

Office365Outlook.V4CalendarPostItem(
    "Calendar",
    "Stalin Test",
    DateAdd(
        DateTimeValue(StartDatePicker.SelectedDate & " 8:00:00 AM"),
        TimeZoneOffset(),
        Minutes
    ),
    DateAdd(
        DateTimeValue(EndDatePicker.SelectedDate & " 8:30:00 AM"),
        TimeZoneOffset(),
        Minutes
    ),
    "(UTC) Coordinated Universal Time",
    {
        body: "Meeting Notes",
        requiredAttendees: Concat(
            RequiredAttendessCombo.SelectedItems.Mail,
            Text(Mail) & ";"
        )
    }
)

StalinPonnusamy_0-1668314730719.png

 

StalinPonnusamy_1-1668314808484.png

 


Thanks, Stalin (Microsoft MVP)
Blog - Learn To Illuminate Blog
YouTube - Learn To Illuminate Videos

Thank you for your reply. But the allday option is required. Not I fixed the bad documentation with the syntax according to your example and some others on the internet.

 

In the runtime mode I get a problem with midnight setting. But how to set it in my timezone?? 

 

Hi @BHS_KI 

 

I tested and got the same error for a full-day event. Looks like this is a product bug. Same functionality I tested using Power Automate, and it works fine.

 

StalinPonnusamy_0-1668387834316.png

 

 

Outlook

StalinPonnusamy_1-1668387866896.png

 

We can create Power Automate, and a call from PowerApps is the solution. Let me know if any questions about developing that functionality.

 


Thanks, Stalin (Microsoft MVP)
Blog - Learn To Illuminate Blog
YouTube - Learn To Illuminate Videos

 

StalinPonnusamy
Super User
Super User

Hi @BHS_KI 

 

Interesting Bug. Please refer to the Blog for the workaround.

 


Thanks, Stalin (Microsoft MVP)
Blog - Learn To Illuminate Blog
YouTube - Learn To Illuminate Videos

Hello Stalin,

you cannot book an event in a shared calendar. 

 

BHS_KI_0-1668501866457.png

 

Hi Stalin,

 

when I enter the date manually it works like you mentioned. But when I pass the date in the same format and with the same value, the flow convert the time without control and produces an error.

 

BHS_KI_1-1668503926575.png

 

Hi @BHS_KI 

 

Make sure your start time like "2022-11-15T00:00:00" and your end time "2022-11-16T00:00:00".

 


Thanks, Stalin (Microsoft MVP)
Blog - Learn To Illuminate Blog
YouTube - Learn To Illuminate Videos

StalinPonnusamy
Super User
Super User

Hi @BHS_KI 

 

Let me know if any help is needed for this post.


Thanks, Stalin (Microsoft MVP)
Blog - Learn To Illuminate Blog
YouTube - Learn To Illuminate Videos

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (3,906)