I'd like to search for Follow-up meeting times using a range (rather than a day at a time). This would enable my team to search for possible meeting dates over the next month, for example.
I'm thinking two date pickers, but I'm really struggling to get it right.
Something that could look like this:
Here's the code options to adjust:
OnStart
Concurrent(Set(MyCalendarID,LookUp(Office365.CalendarGetTables().value,DisplayName=LookUp(CalendarLocalizedLabel,Value=DisplayName).Value).Name);ClearCollect(AllFutureEvents,Office365.GetEventsCalendarView(MyCalendarID,Text(Today(),UTC),Text(DateAdd(Today(),2,Days),UTC)).Values),Set(MyUserProfile,Office365Users.MyProfile().Id),
/*used to determine if meeting attendees are in app user's org*/
Set(MyDomain,Last(Split(User().Email,"@")).Result),
/*used to determine countdown to end of selected meeting*/
Set(HomeTimerStart,Now()));
/*Meetings are defined to be calendar events less than 6 hours in length*/
ClearCollect(MeetingsOnly,Filter(AddColumns(AllFutureEvents,"isCurrent",DateDiff(Start,Now(),Seconds)>0&&DateDiff(Now(),End,Seconds)>0),DateDiff(Start,End,Hours)<6));Set(NumberOfCurrentMeetings,CountRows(Filter(MeetingsOnly,isCurrent)));
/*If a single meeting is happening now, autoselect it*/
If(NumberOfCurrentMeetings=1,Set(AutoSelectMeeting, true );Set(SelectedMeeting,LookUp(MeetingsOnly,isCurrent)))
FollowUpTimesScreen --> Button ('Find Available Times')
ClearCollect(MeetingTimes,AddColumns(
Office365.FindMeetingTimes(
{
MaxCandidates:15,MinimumAttendeePercentage: 1,
MeetingDuration: MeetingDurationSelection.SelectedText.Minutes,
Start:Text(DateAdd(DatePicker1.SelectedDate,MeetingStartRange.SelectedText.Minutes, Minutes), UTC),
End:Text(DateAdd(DatePicker1.SelectedDate, MeetingEndRange.SelectedText.Minutes, Minutes), UTC),
RequiredAttendees:Concat(FollowUpMeetingAttendees,UserPrincipalName & ";")
}
)
.MeetingTimeSuggestions,"StartTime",MeetingTimeSlot.Start.DateTime,
"EndTime",MeetingTimeSlot.End.DateTime));
Set(ShowMeetingTimes, true);
Set(Loading, false)
Gallery
SortByColumns(MeetingTimes,"Confidence",Descending,"StartTime",Ascending)
Solved! Go to Solution.
Hi @whabicht ,
Is the solution I provided above helpful in your scenario?
If the solution I provided above could solved your problem, please consider go ahead to click "Accept as Solution" to identify this thread has been solved.
If you want to get more Meeting Options using your Office365Outlook.FindMeetingTimes() function, please check and see if my response within the following thread would help in your scenario:
On your side, you should modify your formula as below:
Set(Loading, true);
ClearCollect(
MeetingTimes,
AddColumns(
Office365.FindMeetingTimes({
MaxCandidates: 48, // modify formula here
MinimumAttendeePercentage: 1,
MeetingDuration: MeetingDurationSelection.SelectedText.Minutes,
Start: Text(DateAdd(StartDatePicker.SelectedDate, MeetingStartRange.SelectedText.Minutes, Minutes), UTC), // Modify formula here
End: Text(DateAdd(EndDatePicker.SelectedDate, MeetingEndRange.SelectedText.Minutes, Minutes), UTC), // Modify formula here
RequiredAttendees:Concat(FollowUpMeetingAttendees,UserPrincipalName & ";"),
ActivityDomain: "Unrestricted", // add formula here
IsOrganizerOptional: false // add formula here
}).MeetingTimeSuggestions,
"StartTime", MeetingTimeSlot.Start.DateTime,
"EndTime", MeetingTimeSlot.End.DateTime
)
);
Set(ShowMeetingTimes, true);
Set(Loading, false)
Please take a try with above formula, then re-click the "Find Available Times" button again, check if the issue is solved.
Best regards,
Hi @whabicht ,
Could you please share a bit more about your scenario?
Do you want to filter meeting time records using Date time range which across different dates rather than within one day?
I have made a test on my side, please consider take a try with the following workaround:
Within your FollowUpTimesScreen, set the OnSelect property of the "Find Available Times" button to following:
Set(Loading, true);
ClearCollect(
MeetingTimes,
AddColumns(
Office365.FindMeetingTimes({
MaxCandidates:15,
MinimumAttendeePercentage: 1,
MeetingDuration: MeetingDurationSelection.SelectedText.Minutes,
Start: Text(DateAdd(StartDatePicker.SelectedDate, MeetingStartRange.SelectedText.Minutes, Minutes), UTC), // Modify formula here
End: Text(DateAdd(EndDatePicker.SelectedDate, MeetingEndRange.SelectedText.Minutes, Minutes), UTC), // Modify formula here
RequiredAttendees:Concat(FollowUpMeetingAttendees,UserPrincipalName & ";")}).MeetingTimeSuggestions,
"StartTime", MeetingTimeSlot.Start.DateTime,
"EndTime", MeetingTimeSlot.End.DateTime
)
);
Set(ShowMeetingTimes, true);
Set(Loading, false)
Note: Please replace the StartDatePicker and EndDatePicker with actual DatePicker names in your FollowUpTimesScreen.
After that, please re-load your app, then check if the issue is solved.
Best regards,
Thanks @v-xida-msft . It's working like a charm. The last issue I could use help with is figuring out how to display more than 15 meeting options in the gallery. Do you have any idea how I might accomplish that?
You have been super helpful. I appreciate it.
Hi @whabicht ,
Is the solution I provided above helpful in your scenario?
If the solution I provided above could solved your problem, please consider go ahead to click "Accept as Solution" to identify this thread has been solved.
If you want to get more Meeting Options using your Office365Outlook.FindMeetingTimes() function, please check and see if my response within the following thread would help in your scenario:
On your side, you should modify your formula as below:
Set(Loading, true);
ClearCollect(
MeetingTimes,
AddColumns(
Office365.FindMeetingTimes({
MaxCandidates: 48, // modify formula here
MinimumAttendeePercentage: 1,
MeetingDuration: MeetingDurationSelection.SelectedText.Minutes,
Start: Text(DateAdd(StartDatePicker.SelectedDate, MeetingStartRange.SelectedText.Minutes, Minutes), UTC), // Modify formula here
End: Text(DateAdd(EndDatePicker.SelectedDate, MeetingEndRange.SelectedText.Minutes, Minutes), UTC), // Modify formula here
RequiredAttendees:Concat(FollowUpMeetingAttendees,UserPrincipalName & ";"),
ActivityDomain: "Unrestricted", // add formula here
IsOrganizerOptional: false // add formula here
}).MeetingTimeSuggestions,
"StartTime", MeetingTimeSlot.Start.DateTime,
"EndTime", MeetingTimeSlot.End.DateTime
)
);
Set(ShowMeetingTimes, true);
Set(Loading, false)
Please take a try with above formula, then re-click the "Find Available Times" button again, check if the issue is solved.
Best regards,
Stay up tp date on the latest blogs and activities in the community News & Announcements.
Mark your calendars and join us for the next Power Apps Community Call on January 20th, 8a PST
Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.
User | Count |
---|---|
206 | |
187 | |
82 | |
51 | |
37 |
User | Count |
---|---|
288 | |
244 | |
121 | |
76 | |
55 |