cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
randomsky
Helper I
Helper I

Calendar free busy information

As per this post: https://powerusers.microsoft.com/t5/Building-Power-Apps/Power-APPS-Calendar-getSchedule/td-p/344553 I'm trying to read the free busy information for a user using a custom connector. From testing the connector within the app it shows that it is retrieving the information correctly since I see it in the collection once it executes.

randomsky_0-1641191078726.png

 

After the code executes I'm also able to get the users ID using this code:

ClearCollect(
    UserFreeBusyId,
    ForAll(
        UserFreeBusy.value,
        value.scheduleId
    )
);

 

However when I attempt to retrieve the start and end date and time of the calendar entry, it doesn't seem to work:

randomsky_2-1641191274824.png

I was hoping that the same approach for accessing the nested data would work as per this post: https://powerusers.microsoft.com/t5/Building-Power-Apps/Understanding-Nested-Collections/td-p/336270 however it doesn't seem to be working. Any guidance appreciated. Thanks.

1 ACCEPTED SOLUTION

Accepted Solutions
v-xiaochen-msft
Community Support
Community Support

Hi @randomsky ,

 

You could see the preview of your output in the formula.

For example:

vxiaochenmsft_0-1641283119611.png

 

If your output is like the values in my image ,you could try to use ungroup function.

vxiaochenmsft_1-1641283201388.png

 

Best Regards,

Wearsky

 

 

View solution in original post

11 REPLIES 11
Eelman
Super User
Super User

@randomsky 

I’d recommend tagging the MS employee who provided the solution in your first link and also a description of the error you are seeing.

 

randomsky
Helper I
Helper I

@Eelman , the errors are:

randomsky_0-1641248804797.png

and

randomsky_1-1641248851840.png

 

If I remove the dot after the scheduleItems the error goes away but it doesn't give me the nested data under the scheduleItems sub-collection. 

 

randomsky_2-1641248969230.png

 

 

 

 

 

randomsky
Helper I
Helper I

Any thoughts @v-xida-msft ?

v-xiaochen-msft
Community Support
Community Support

Hi @randomsky ,

 

Please provide the values in the value column.

vxiaochenmsft_0-1641261607063.png

 

Best Regards,

Wearsky

 

@v-xiaochen-msft , these are the values:

randomsky_0-1641267998361.pngrandomsky_1-1641268032984.pngrandomsky_2-1641268054340.png

 

 

 

 

v-xiaochen-msft
Community Support
Community Support

Hi @randomsky ,

 

Why is there a'.' at the end of your formula?

vxiaochenmsft_0-1641276920932.png

 

Best Regards,

Wearsky

@v-xiaochen-msft , as per this post: https://powerusers.microsoft.com/t5/Building-Power-Apps/Understanding-Nested-Collections/td-p/336270 I was trying to get to the next level of the collection under scheduleItems which in this case is either start, end or busy however when I add the dot it doesn't show me any of those columns. When I remove the dot the error goes away but it then does not give me the start and end dates of the schedule.

v-xiaochen-msft
Community Support
Community Support

Hi @randomsky ,

 

You could see the preview of your output in the formula.

For example:

vxiaochenmsft_0-1641283119611.png

 

If your output is like the values in my image ,you could try to use ungroup function.

vxiaochenmsft_1-1641283201388.png

 

Best Regards,

Wearsky

 

 

@v-xiaochen-msft , yes, the forall preview shows a table similar to yours:

randomsky_0-1641336618647.png

I then used the ungroup function to try and get to the start and end date/time:

randomsky_1-1641336700249.png

and this is what it gets me to:

randomsky_2-1641336730224.png

I then tried to access the start date time using a variable:

randomsky_3-1641336959434.png

And when I try to display the value of the variable it says that it is of type Table

randomsky_4-1641337013743.png

 

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Users online (1,201)