Skip to main content

Notifications

Power Apps - Power Apps Experimental Features
Suggested answer

How to display data in the forms in different pages that use different source of sharepoint lists

Posted on 22 Nov 2024 02:25:39 by

Hi community, I'm currently creating a power app with 4 screens. Three of them are forms which uses data from 3 different SharePoint lists.

Another one contains vertical gallery which will displays all the user input record and here user can create/edit/delete their record. This gallery also uses different SharePoint list which keeps user transactions.

Each record in all 4 SharePoints relate to a column called processID.

Until this step, I have a question regarding how to retrieve and display the data when user click on edit(pencil) button on the gallery screen. The user input data needed to be show in the text input of every forms.

If not using function Lookup() or Filter(), is there any other ways to display data to the form control. Or if using these functions is the only way to display data in the forms

  • WarrenBelz Profile Picture
    WarrenBelz 143,081 on 24 Nov 2024 at 05:40:18
    How to display data in the forms in different pages that use different source of sharepoint lists
    The detail here (which you have not posted) is the "key" or common field linking the lists. I generally use a numeric field (I call it IDRef) containing the ID of the "parent" list, although you can link/relate the lists on any common text or numeric field.
    There are a couple of options to display these "other list" fields in a gallery including a Lookup on each one in a Text Label in the gallery (processor intensive and a lot of API calls) or if both the reference list/s and the returned data set to your gallery are under your Data Row Limit, you can use AddColumns in the Gallery Items with some "pre defining" of the source (I will get further into this if I am correct in what you are trying to do and you supply some more detail on your data structure and required field names and types).
  • Suggested answer
    Inogic Profile Picture
    Inogic 830 on 22 Nov 2024 at 12:18:04
    How to display data in the forms in different pages that use different source of sharepoint lists
    Hi,
     
    One another way to retrieve and display data without using Lookup() or Filter() is by using collections. When a user clicks the Edit button in the gallery, you can store the selected record in a collection, and then bind the form controls to that collection.
    1. Step 1: Store the Selected Record in a Collection
      In the OnSelect property of the Edit button inside the gallery, use ClearCollect() to store the selected record in a collection:
    OnSelect = ClearCollect(SelectedRecordCollection, ThisItem);
                        Navigate(DisplayFormScreen);
    1. Step 2: Bind the Form to the Collection
      On the DisplayFormScreen, set the Item property of the form to the first item in the SelectedRecordCollection:
    Item = First(SelectedRecordCollection)
    1. Step 3: Display Data in Form Controls
      The form controls will automatically display the selected record’s data. For example, if you have a TextInput for the Title field, it will be populated with the value from the collection:
    Default = First(SelectedRecordCollection).Title
     
    Hope this helps.
     
    Thanks!
    Inogic Professional Services: Power Platform/Dynamics 365 CRM
    An expert technical extension for your techno-functional business needs
    Drop an email at crm@inogic.com 
    Service: https://www.inogic.com/services/ 
    Tips and Tricks: https://www.inogic.com/blog/ â€‹â€‹â€‹â€‹â€‹â€‹â€‹

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

October 2024 Newsletter…

October 2024 Community Newsletter…

Community Update Oct 28…

Power Platform Community Update…

Tuesday Tip #4 How to Conntact Support…

Welcome to a brand new series, Tuesday Tips…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 143,081

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 63,795

Leaderboard

Featured topics