cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
TBuente
Level 8

Collect unavailable Outlook rooms?

Hi,

 

I am building a conference room scheduling application. I am using Outlook, with each conference room having its own profile. I am trying to figure out a way to collect all of the UNAVAILABLE rooms for the current time (Now()).

 

I am using the Book a Room template, but I am having troubles coming up with a method to collect unavailable rooms.

 

Alternatively, if anyone can show me a method for the Book a Room application to collect Available Rooms simply only by the start time, that would be great. I would like to know this because I am using a timer to refresh an internal clock in my application. I want the app to refresh every 30 seconds, showing if the room is booked or not.

1 ACCEPTED SOLUTION

Accepted Solutions
TBuente
Level 8

Re: Collect unavailable Outlook rooms?

I have actually found a solution to my second question.

The workaround that I found, was to utilize the GetEventsCalendarViewV3. To do this, I had to create a start and end UTC, which I did with:

 

Set(StartUTC, Text(DateAdd(StartDateTime, TimeZoneOffset(), Minutes), "[$-en-US]yyyy-mm-ddThh:mm") & ":00.000Z");
Set(EndUTC, Text(DateAdd(EndDateTime, TimeZoneOffset(), Minutes), "[$-en-US]yyyy-mm-ddThh:mm") & ":00.000Z");

 

(StartDateTime is Now() and EndDateTime is Now() + whatever button they select, example: 15 minute meeting, 30 minute meeting, etc)

 

From here, I had to use the following codes:

 

Set(OlympusID, LookUp(Office365.CalendarGetTables().value, DisplayName = "Olympus").Name);
Office365.GetEventsCalendarViewV3(OlympusID, StartUTC, EndUTC).value

Olympus is the name of my conference room. Basically, these series of functions worked, as it will even display reoccurring events.

 

This method works, as I can collect a room availability based on a start-to-end time frame.

 

Thank you for the assistance!

View solution in original post

2 REPLIES 2
Community Support Team
Community Support Team

Re: Collect unavailable Outlook rooms?

Hi @TBuente ,

 

Please check the Refresh function here:

https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-refresh

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
TBuente
Level 8

Re: Collect unavailable Outlook rooms?

I have actually found a solution to my second question.

The workaround that I found, was to utilize the GetEventsCalendarViewV3. To do this, I had to create a start and end UTC, which I did with:

 

Set(StartUTC, Text(DateAdd(StartDateTime, TimeZoneOffset(), Minutes), "[$-en-US]yyyy-mm-ddThh:mm") & ":00.000Z");
Set(EndUTC, Text(DateAdd(EndDateTime, TimeZoneOffset(), Minutes), "[$-en-US]yyyy-mm-ddThh:mm") & ":00.000Z");

 

(StartDateTime is Now() and EndDateTime is Now() + whatever button they select, example: 15 minute meeting, 30 minute meeting, etc)

 

From here, I had to use the following codes:

 

Set(OlympusID, LookUp(Office365.CalendarGetTables().value, DisplayName = "Olympus").Name);
Office365.GetEventsCalendarViewV3(OlympusID, StartUTC, EndUTC).value

Olympus is the name of my conference room. Basically, these series of functions worked, as it will even display reoccurring events.

 

This method works, as I can collect a room availability based on a start-to-end time frame.

 

Thank you for the assistance!

View solution in original post

Helpful resources

Announcements
thirdimage

Power Apps Super User Class of 2020

Check it out!

thirdimage

New Badges

Check it out!

thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Solution Authors
Top Kudoed Authors
Users online (4,340)