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

Show data from one Gallery(based on location) in another Gallery(summary of all location)

Hi Team,

Need some help here.

 

I have two Gallery once each screen.

First one shows a details of items AND their Total.

Screen 1 : Gallery1_1

vikna_0-1619743559193.png

 

On the next screen, it should show ONLY the total.

Screen 2 : Galery3

vikna_1-1619743565336.png

 

I used Gallery1_1.Selected.TOTAL and it ends up showing the same total from which is 89 instead of 89 in one box and 11 in the other box.

 

Please advise the correct code to use.

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-albai-msft
Community Support
Community Support

Hi @vikna ,

I did a test on my side, here is my steps for you reference:

1. Here is my first gallery called “Gallery1_1”. The item name show in a control called “LaptopName1”, and the total number show in a control called “TextInput1_13” :

v-albai-msft_0-1619767190860.png

 

2. Here is my second gallery called “Galery3”, The item name show in a control called “LaptopName2”, and the total number show in a control called “Total2” :

 

v-albai-msft_1-1619767190866.png

 

So just set Text property of the Total2 control to below to get the right total value(remember to replace to your control name):

LookUp(Gallery1_1.AllItems,LaptopName1.Text=LaptopName2.Text).TextInput1_13.Text

Best regards,

Allen

View solution in original post

8 REPLIES 8
Jagadeeshk
Responsive Resident
Responsive Resident

Can you pls elaborate how you are arriving total value in first gallery?

Is it a column or summing other columns 

Hi Jagadeeshk,

I just used simple + equation from each TextInput.Text

 

vikna_1-1619746665374.png

 

Basically, its a gallery with Text Input.

 

 

v-albai-msft
Community Support
Community Support

Hi @vikna ,

I did a test on my side, here is my steps for you reference:

1. Here is my first gallery called “Gallery1_1”. The item name show in a control called “LaptopName1”, and the total number show in a control called “TextInput1_13” :

v-albai-msft_0-1619767190860.png

 

2. Here is my second gallery called “Galery3”, The item name show in a control called “LaptopName2”, and the total number show in a control called “Total2” :

 

v-albai-msft_1-1619767190866.png

 

So just set Text property of the Total2 control to below to get the right total value(remember to replace to your control name):

LookUp(Gallery1_1.AllItems,LaptopName1.Text=LaptopName2.Text).TextInput1_13.Text

Best regards,

Allen

View solution in original post

vikna
Helper III
Helper III

Thank you very much!! It worked!
Really appreciate your assistance.

 

 

Hi Sir,

 

The app is updating correctly

vikna_2-1619787315444.png

 

However, the second row data goes missing if I close and open the app

 

vikna_0-1619835395292.png

 

 

 

I've added the below code to "On Visible" so that it will save to my database the moment it opens the page : 

ForAll(Filter(GalleryLaptop.AllItems, Toggle1.Value = true), Patch(SUMMARY_LAPTOP, ThisRecord, {LUTONG:TextInput6_1.Text, 'MENARA SHELL':TextInput6_2.Text, 'PLAZA SHELL':TextInput6_3.Text, 'LABUAN SUPPLY BASE':TextInput6_4.Text, TOTAL:TextInput6_5.Text})) ;
ForAll(Filter(GalleryAccessories.AllItems, Toggle2.Value = true), Patch(SUMMARY_ACCESSORIES, ThisRecord, {LUTONG:TextInput11.Text, 'MENARA SHELL':TextInput11_1.Text, 'PLAZA SHELL':TextInput11_2.Text, 'LABUAN SUPPLY BASE':TextInput11_3.Text, TOTAL:TextInput11_4.Text}))

 

It works, but again, if we close the app and open it again the second row goes missing.

Would you be able to advise ?

 

 

 

Hi @vikna ,

As this is a new question, I would suggest you post it in a new thread, it would make others easier to focus on one question in one single thread and it will benefit other community members who stuck with the same question. 

Thanks for your understanding!

Best regards,

Allen

vikna
Helper III
Helper III

Hi @v-albai-msft ,

Hoping you could advise why the second row is not being saved when I close and open the app?

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Users online (1,315)