Skip to main content

Notifications

Community site session details

Community site session details

Session Id : wj0zFXnMNf8GsFVQ1YhaZZ
Power Apps - Building Power Apps
Unanswered

Display Form Record based on value from a Gallery

Like (0) ShareShare
ReportReport
Posted on 20 Jan 2020 20:04:11 by

Howdy, 

 

I'm working on an inventory PowerApp and I'd like to have a screen that has three items - a gallery of users (UserGallery), a display form with the record from the selected user (UserInfo), and another display from that shows the details of the device that's assigned to the user (StationInfo). The information for this is on two Sharepoint lists - one for Users and another for Assets. The User list has a lookup column that picks the Asset by the title name. 

 

I've tried a lookup, but I get an error with the equal size not being valid. Is this even possible or do have the lists built incorrectly for this to work? Thanks in advance for the help. 

Categories:
  • kidvallejo Profile Picture
    100 on 21 Jan 2020 at 07:47:27
    Re: Display Form Record based on value from a Gallery

    If it is a dropdown selector then that would be the issue...

     

    Change it to:

    First(Filter(Assets, Title = Text(DataCardValue9.Selected.Value)))

     

    *note .value may be different depending on how your list is created.

  • Community Power Platform Member Profile Picture
    on 20 Jan 2020 at 23:56:10
    Re: Display Form Record based on value from a Gallery

    Tried both to no avail, still showing as invalid. As a test, I added a text input and set the list for the Asset form 

    First(Filter(Assets, Title = TextInput1))) and that worked. The station field in the User Form is a dropdown selector, not just a text input, could this be why First(Filter(Assets, Title = Text(DataCardValue9))) not working? 

  • kidvallejo Profile Picture
    100 on 20 Jan 2020 at 22:00:19
    Re: Display Form Record based on value from a Gallery

    take out the .text if it comes up with a mismatch then it could need text(datacardvalue9)

  • Community Power Platform Member Profile Picture
    on 20 Jan 2020 at 21:58:04
    Re: Display Form Record based on value from a Gallery

    Updated First(Filter(Assets, Title = DataCard9.text)) to First(Filter(Assets, Title = DataCardValue9.text)) and still nothing. 

    For the heck of it, I also tried to make the User Form in Edit mode to see if that would work, but I'm still getting an "Invalid Argument Type" error.

     

    By the way, thanks for your help with this, I appreciate it greatly.

  • kidvallejo Profile Picture
    100 on 20 Jan 2020 at 21:44:54
    Re: Display Form Record based on value from a Gallery

    Ok the issue is the datacard part... should be datacardvalue9

     

    Also, temporarily add a button and put the following: Newform(UserFormName); NewForm(AssetFormName)

     

     

  • Community Power Platform Member Profile Picture
    on 20 Jan 2020 at 21:40:21
    Re: Display Form Record based on value from a Gallery

    The asset form should lookup from the user form. In all, I'd select the user from the user gallery, the userinfo form (display mode) would show the users' info and then the stationinfo form (in edit mode?) would display the station's info based on matching the title of the asset to the computer name field in the userinfo form (datacard9)

     

    I added an Asset form in edit mode and tried the formula, but still didn't get any results. 

  • kidvallejo Profile Picture
    100 on 20 Jan 2020 at 21:21:06
    Re: Display Form Record based on value from a Gallery

    Sorry, I think I misread something earlier...Do they select the asset or does it look up from the user field?

     

    If the asset form is looking up from the user form (asset form should be an edit form mode) and the item should be set to:

    First(Filter(Assets, Title = datacard9.text))

     

     

  • Community Power Platform Member Profile Picture
    on 20 Jan 2020 at 21:06:26
    Re: Display Form Record based on value from a Gallery

    There are 148 assets. I tried both of those formulas and they did not display any results. 

    To be sure, that formula needs to be entered into the Item field of the Display Form correct? 

  • kidvallejo Profile Picture
    100 on 20 Jan 2020 at 20:53:12
    Re: Display Form Record based on value from a Gallery
    Ok, how many assets do you have I sharepoint to lookup? If it's over 500 that could be your issue, try using:

    Search(Assets,datacard9.text,title) or

    First(Filter(assets,title=datacard9.text),title)
  • Community Power Platform Member Profile Picture
    on 20 Jan 2020 at 20:44:45
    Re: Display Form Record based on value from a Gallery

    So based on the following working, 

    LookUp(Assets, Title = "Station 94")

     

    I tried

    LookUp(Assets, Title = UserGallery.Selected.Computer) &

    LookUp(Assets, Title = DataCardValue9) &

    LookUp(Assets, Title = DataCardValue9.Text)

    (Where DataCardValue9 is the DataCard showing the station name that would match the title in assets)

     

    Those didn't work and I'm guessing it's because I don't have that formatted correctly.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

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

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Power Apps - Building Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 58 Most Valuable Professional

#2
mmbr1606 Profile Picture

mmbr1606 41 Super User 2025 Season 1

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 36

Overall leaderboard