cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
kinghnvn
Helper V
Helper V

Show text with LookUp

Hi all,

 

I have a DeskInfo SharePoint list and I set icon on map for each desk

kinghnvn_0-1639464304619.png

When user book a desk it store information in BookedInfo sharepoint list

kinghnvn_1-1639464470409.png

If desk is booked and when I click on the icon to select a desk. How can show text with Employee booked the desk?

 

kinghnvn_2-1639464521279.png

 

Text Result -> Employee: TienaVu

@StalinPonnusamy 

1 ACCEPTED SOLUTION

Accepted Solutions
StalinPonnusamy
Super User
Super User

Hi @kinghnvn 

 

Need to use Lookup to get employee information for the desk that booked

 

LookUp(
    SPList,
    BookDate = BookingDate.SelectedDate && Office.Id = MainGallery.Selected.ID
).Employee.DisplayName

 

To Avoid Delegation

With(
    {
        item: Filter(
            OfficeBooking,
            BookDate = BookingDate.SelectedDate
        )
    },
    LookUp(
        item,
        Office.Id = MainGallery.Selected.ID
    ).Employee.DisplayName
)

 

In this example, I selected desk 3 booked by "Diego S"

StalinPonnusamy_1-1639488148082.png

In your case, you need to use StartDatetime and EndDatetime with Desk ID.


Thanks,
Stalin - Learn To Illuminate

 

 

 

View solution in original post

6 REPLIES 6
AJ_Z
Super User
Super User

What columns exist in BookedInfo. is the DeskName or any unique value (e.g. guid or number or name) the same across both of them. Is there a columns linked to the colleague. If so you could LookUp(BookedInfo, DeskName = DeskName).Colleague . if there is a data filter you would need to include that in the lookup. Let me know if this needs a bit more discussion and it would help if i know what colums we have in bookedinfo

If you appreciated my comments/responses please be sure to Like/Kudo them it really does make me smile 🙂 !

PabloRoldan
Resolver I
Resolver I

Hi,

Connect your list as data source

PabloRoldan_1-1639468787044.png

 

Add a gallery control and in Items Property set DeskInfo

PabloRoldan_2-1639468820902.png

Select first row in the gallery and add your image,

 

the select the image and OnSelect Action paste this code

 

Notify(ThisItem.Employee)

 

 If you click that image an notification will pop out

PabloRoldan_4-1639469170662.png

 

 

regards

 

if it was helpful please consider mark it as answer ✔✔

What columns exist in BookedInfo. is the DeskName or any unique value (e.g. guid or number or name) the same across both of them.

 

->

DeskInfo list

ID: number

Title: Text

 

BookedInfo list

Title: Text

Employee: Text

 

When I click on the icon it will show desk name (Desk 018) (in title column/ DeskInfo)

When I booked the desk, it will record in Title column (BookedInfo) with Employee name (TienaVu)

 

I want to show the text when another user click on this icon with the same desk name, it will show text "Booked by employee: TienaVu"

 

 

I have two SharePoint list and the DeskInfo list have no Employee columns so the code could not run.

 

DeskInfo list

ID: number

Title: Text

 

BookedInfo list

Title: Text

Employee: Text

StalinPonnusamy
Super User
Super User

Hi @kinghnvn 

 

Need to use Lookup to get employee information for the desk that booked

 

LookUp(
    SPList,
    BookDate = BookingDate.SelectedDate && Office.Id = MainGallery.Selected.ID
).Employee.DisplayName

 

To Avoid Delegation

With(
    {
        item: Filter(
            OfficeBooking,
            BookDate = BookingDate.SelectedDate
        )
    },
    LookUp(
        item,
        Office.Id = MainGallery.Selected.ID
    ).Employee.DisplayName
)

 

In this example, I selected desk 3 booked by "Diego S"

StalinPonnusamy_1-1639488148082.png

In your case, you need to use StartDatetime and EndDatetime with Desk ID.


Thanks,
Stalin - Learn To Illuminate

 

 

 

that's great! thank you so much

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 (2,940)