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

Click to show details from another Sharepoint list

Hi Community,

 

I have a SharePoint List named Header and another SharePoint List named Details. Header is a report header which has fields such as Title, HeaderID1, TotalClaimAmount, ClaimSubmission Date. Details shows the individual expense items under the header.

 

In PowerApps, I have a HomePage screen shown below. The gallery is from Header. The idea is that once I click on ">" icon, it will bring me to another screen with individual expense details from the report.

 

hmpage.PNG

 

This is what I get when I click on the Homepage to navigate to the report details. The bottom half of the screen is a gallery with datasource Details. It should extract from Details all the expense details under the same report. All expense details are set to have the same ID as the report they are under.

 

details.PNG

 

 

Under Total Claim Amount, it should display the total claim amount shown in Header, after doing a match between the ID under Summary.Selected and HeaderID1 under Header.

 

I do not know how to write the formula for this. I tried Filter(Header, Summary.Selected.ID = Header1) but I do not know how to include TotalClaimAmount in.

 

Kindly advise. Thank you!

2 ACCEPTED SOLUTIONS

Accepted Solutions
Community Support
Community Support

Hi @elleeyl ,

Do you mean that: in homescreen, you have a gallery for Header, you want to display related Details items based on the selection of homescreen?

If so, I suggest you set the buttom gallery's Items in individual expense details screen:

Filter(Details,ID=galleryhomescren.Selected.HeaderID1)

set the top display form in  individual expense details screen:

                                         datasource: Header

                                         Item :

galleryhomescren.Selected

Then, in individual expense details screen, the top place will display the item of Header that you select in homescreen.

The buttom place will display the filtered Details items.

 

 

 

Best regards,

Community Support Team _ Phoebe Liu
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

Hi @elleeyl  and @v-yutliu-msft 

 

I just wanted to add some clarification here. The ID field is generated by SharePoint and is unique...each item in a list will have a different ID. You said that "All expense details are set to have the same ID as the report they are under" but I think you must mean that all the Details records have another field that contains the ID of the Header that they are related to. Is that the field that is called HeaderID1 and is it on the Details list?

I'm presuming that it is the Gallery on the Home Page that you are referring to as "Summary".

 

If so, your bottom gallery will need to use that column name for the Gallery's items:

e.g 

Filter(Details,HeaderID1=Summary.Selected.ID)

 

Are you trying to calculate the value of Total Claim Amount from the list of details that are related to this Header, or are you trying to display the value from the selected Header record?

View solution in original post

3 REPLIES 3
Helper III
Helper III

-

Community Support
Community Support

Hi @elleeyl ,

Do you mean that: in homescreen, you have a gallery for Header, you want to display related Details items based on the selection of homescreen?

If so, I suggest you set the buttom gallery's Items in individual expense details screen:

Filter(Details,ID=galleryhomescren.Selected.HeaderID1)

set the top display form in  individual expense details screen:

                                         datasource: Header

                                         Item :

galleryhomescren.Selected

Then, in individual expense details screen, the top place will display the item of Header that you select in homescreen.

The buttom place will display the filtered Details items.

 

 

 

Best regards,

Community Support Team _ Phoebe Liu
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

Hi @elleeyl  and @v-yutliu-msft 

 

I just wanted to add some clarification here. The ID field is generated by SharePoint and is unique...each item in a list will have a different ID. You said that "All expense details are set to have the same ID as the report they are under" but I think you must mean that all the Details records have another field that contains the ID of the Header that they are related to. Is that the field that is called HeaderID1 and is it on the Details list?

I'm presuming that it is the Gallery on the Home Page that you are referring to as "Summary".

 

If so, your bottom gallery will need to use that column name for the Gallery's items:

e.g 

Filter(Details,HeaderID1=Summary.Selected.ID)

 

Are you trying to calculate the value of Total Claim Amount from the list of details that are related to this Header, or are you trying to display the value from the selected Header record?

View solution in original post

Helpful resources

Announcements
New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

Top Solution Authors
Top Kudoed Authors
Users online (81,088)