Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Building Power Apps
Answered

'Office365Outlook.GetEventsCalendarViewV2' fails the first run, but works every time after

(0) ShareShare
ReportReport
Posted on by

 

I've built a Room Reservation app, and one of the features allows you to view your Calendar (using Outlook as a connector). Oddly enough, when I 'play' the app for the first time, I click "Calendar", this error comes up and no events are populated in my calendar:

 

jharville_4-1636042511995.png

 

jharville_3-1636042472515.png

 

...and once I go back to the main screen and re-click on Calendar, it populates my Calendar and no error is thrown:

 

jharville_5-1636042629554.png

 

This issue does not exist when my app is in Edit mode. When I click on Calendar for the first time when in Edit mode, everything loads as desired and no error is thrown. 

 

Here is the code for my 'Items' property of the calendar events:

 

jharville_0-1636043164191.png

 

Would anybody know the cause behind the calendar failing to load the first time (when in 'play mode'), but working every time after?

 

 

 

  • Verified answer
    jharville Profile Picture
    on at
    Re: 'Office365Outlook.GetEventsCalendarViewV2' fails the first run, but works every time after

    Hi Randy!

     

    Thank you for your response. I tried using V3 (as opposed to V2) and it was still throwing the same error as shown in my screenshots above, just replacing the "V2" text with "V3." 

     

    I actually found the issue was my gallery (populated by a collection generated by my OnVisible property) wasn't populating when I first accessed the screen. The expression to collect calendar events was using a variable that had no value when the screen first loaded. We found the variable was coming from the Dropdown control on the calendar screen, and when the OnVisible is first run, there is no selected item for the dropdown so the variable is empty. It was resolved by finding the correct calendar, assigning it to a variable, and using the variable in the ClearCollect() expression.

     

     

  • RandyHayes Profile Picture
    76,287 Super User 2024 Season 1 on at
    Re: 'Office365Outlook.GetEventsCalendarViewV2' fails the first run, but works every time after

    @jharville 

    The issue would seem to be with where you are getting the GetEventsCalendarViewV2 (which by the way is deprecated and V3 should be used).

    What is the formula for that action?

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,524 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,906 Most Valuable Professional

Leaderboard