cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Tiffany-Jo
Helper V
Helper V

Book A Room Template Room Lists

Hi

I would like to set that user only could find one room name under RoomsLists, I tried to change below but it is not working.

Search(RoomsLists, SearchBox1.Text, "Name.Selected=CAKIR Rooms")

 

Collection.PNG1106.PNG

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Tiffany-Jo ,

Please take a try with the following workaround:

Set the Text property of the LabelMeetingLocation_2 Label within RoomSelectScreen to following:

RoomsListsGallery.Selected.Name

or

LookUp(RoomsLists, Name = "CAKIR Rooms").Name

 

Then set the OnVisible property of the RoomSelectScreen to following:

Set(CalendarFromSelectMeeting, false);
If(DateTimeRoomChange,
    Set(AvailableRoomsCounter, 1);
    UpdateContext({ShowLoading: true});
    Set(RoomsLeft, Blank());
    Set(DateTimeRoomChange, false);
    If(!NoRoomsList,
        ClearCollect(AllRooms, Office365.GetRoomsInRoomList(LookUp(RoomsLists, Name = "CAKIR Rooms").Address).value)   /* <-- Modify formula here */
    );
    If(CountRows(AllRooms) > 20,
        Set(AllRoomsConnector, Concat(FirstN(AllRooms, 20), Address & ";")),
        Set(AllRoomsConnector, Concat(AllRooms, Address & ";"))
    );

    ClearCollect(AvailableRooms, Office365.FindMeetingTimes({RequiredAttendees: AllRoomsConnector, IsOrganizerOptional: true, 
        Start: StartDateTimeUTC, End: EndDateTimeUTC, MeetingDuration: DateDiff(StartDateTime, EndDateTime, Minutes),
        MinimumAttendeePercentage: "1", ActivityDomain: "Unrestricted"}));

    ClearCollect(AvailableRoomsSorted, SortByColumns(First(AvailableRooms).MeetingTimeSuggestions, "Confidence", Descending));

    ClearCollect(AvailableRoomsConcat, Concat(Filter(First(AvailableRoomsSorted).AttendeeAvailability, Availability = "Free"), 
        Attendee.EmailAddress.Address, ","));

    ClearCollect(AvailableRoomEmails, Split(First(AvailableRoomsConcat).Value, ","));

    ClearCollect(AvailableRoomEmailName, AddColumns(RenameColumns(AvailableRoomEmails, "Result", "Email"), "Name", 
        LookUp(AllRooms, Email = Address).Name));

    UpdateContext({ShowLoading: false});
    Set(RoomsLeft, CountRows(AllRooms) - 20 * AvailableRoomsCounter)
)

Please consider take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-xida-msft
Community Support
Community Support

HI @Tiffany-Jo ,

Could you please share a bit more about your scenario?

Do you want to only display single one room name (e.g. 'CAKIR Rooms') under the RoomsListsGallery?

 

I have made a test on my side, please consider take a try with the following workaround:

Set the Items property of the RoomsListsGallery to following:

Search(
       Filter(RoomsLists, Name = "CAKIR Rooms"),    /* <-- Find the RoomsList based on specific room name */
       SearchBox1.Text,
       "Name"
)

Please consider take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

hi @v-xida-msft 

 

Thank you .It is working.

Since the meeting room has been specified to only one room on RoomListSelectScreen.

Is there any way to add that meeting room name to RoomSelectScreen , and show all of the available meeting rooms directly?

We don't want to select the roomlist location because we only use one location.

110802.PNG1108.PNG

Hi @Tiffany-Jo ,

Please take a try with the following workaround:

Set the Text property of the LabelMeetingLocation_2 Label within RoomSelectScreen to following:

RoomsListsGallery.Selected.Name

or

LookUp(RoomsLists, Name = "CAKIR Rooms").Name

 

Then set the OnVisible property of the RoomSelectScreen to following:

Set(CalendarFromSelectMeeting, false);
If(DateTimeRoomChange,
    Set(AvailableRoomsCounter, 1);
    UpdateContext({ShowLoading: true});
    Set(RoomsLeft, Blank());
    Set(DateTimeRoomChange, false);
    If(!NoRoomsList,
        ClearCollect(AllRooms, Office365.GetRoomsInRoomList(LookUp(RoomsLists, Name = "CAKIR Rooms").Address).value)   /* <-- Modify formula here */
    );
    If(CountRows(AllRooms) > 20,
        Set(AllRoomsConnector, Concat(FirstN(AllRooms, 20), Address & ";")),
        Set(AllRoomsConnector, Concat(AllRooms, Address & ";"))
    );

    ClearCollect(AvailableRooms, Office365.FindMeetingTimes({RequiredAttendees: AllRoomsConnector, IsOrganizerOptional: true, 
        Start: StartDateTimeUTC, End: EndDateTimeUTC, MeetingDuration: DateDiff(StartDateTime, EndDateTime, Minutes),
        MinimumAttendeePercentage: "1", ActivityDomain: "Unrestricted"}));

    ClearCollect(AvailableRoomsSorted, SortByColumns(First(AvailableRooms).MeetingTimeSuggestions, "Confidence", Descending));

    ClearCollect(AvailableRoomsConcat, Concat(Filter(First(AvailableRoomsSorted).AttendeeAvailability, Availability = "Free"), 
        Attendee.EmailAddress.Address, ","));

    ClearCollect(AvailableRoomEmails, Split(First(AvailableRoomsConcat).Value, ","));

    ClearCollect(AvailableRoomEmailName, AddColumns(RenameColumns(AvailableRoomEmails, "Result", "Email"), "Name", 
        LookUp(AllRooms, Email = Address).Name));

    UpdateContext({ShowLoading: false});
    Set(RoomsLeft, CountRows(AllRooms) - 20 * AvailableRoomsCounter)
)

Please consider take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Power Apps Community Call Jan. 2022 768x460.png

Power Apps Community Call

Please join us on Wednesday, January 19th, at 8a PDT. Come and learn from our amazing speakers!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Solution Authors
Top Kudoed Authors
Users online (1,247)