Skip to main content

Notifications

Community site session details
Power Apps - Building Power Apps
Answered

Embedded canvas app get the selected lookup field value

Like (0) ShareShare
ReportReport
Posted on 21 Nov 2019 22:06:30 by 55

Please see the screenshots, I used the following examples from previous messages and Microsoft guides and any variant that I could think of:

LookUp(Accounts, Account = GUID(First(ModelDrivenFormIntegration.Data).ItemId)).'Primary Contact'.'Full Name'
LookUp(Accounts, Account = ModelDrivenFormIntegration.Item.Account).'Primary Contact'.'Full Name' 

I have an embedded a canvas app for Work Order entity and every Work Order has a Vessel associated with it. I am aware that I can retrieve any field from the work order, except the lookup fields and vessel is a look up field in the Work Order record. Please see embedded 3 screenshot, where I am trying to retrieve the vessel identifier. I have entered the formulas given as examples, but they give me errors - I thought it may be because its a list of items (which by the way show if I click on the dropdown) , so I added a label and entered the following: 

LookUp('Work Orders','WO Number'=[@ModelDrivenFormIntegration].Item.'WO Number').'Service Account'.'Account Name'

As you can see in attachment, I have no errors but no value is returned. No matter what field from the vessel entity I am trying to retrieve , the results are the same. I attached another example with no lookup:  [@ModelDrivenFormIntegration].Item.Vessel.'Hull Number' 

I know answers have been provided in previous posts and even guidance from Microsoft, but it does not work for me....

What should I do?

  • Verified answer
    PowerAddict Profile Picture
    7,314 Most Valuable Professional on 22 Nov 2019 at 04:25:38
    Re: Embedded canvas app get the selected lookup field value
    Ok try this.
    1. Add another screen in your app (don't worry about its UI, we wont expose tha screen to the end user).
    2. Add a gallery (Gallery1) of work orders with the items property set to Work Orders. Make sure you see a list of work orders
    4. Now set the items property of this gallery to something like this: Filter('Work Orders','WO Number'=[@ModelDrivenFormIntegration].Item.'WO Number')
    5. Now in your main screen wherever you want to reference your work order, use something like this: First(Gallery1.AllItems) so for work order number it would be First(Gallery1.AllItems).'WO Number'

    Let me know how this goes.

    ---
    If you like this reply, please give kudos. And if this solves your problem, please accept this reply as the solution. Thanks!

    Hardit Bhatia
    https://thepoweraddict.com

Helpful resources

Quick Links

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Leaderboard > Power Apps - Building Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 285 Most Valuable Professional

#2
MS.Ragavendar Profile Picture

MS.Ragavendar 146

#3
stampcoin Profile Picture

stampcoin 130

Overall leaderboard
Loading complete