cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MrDzem
New Member

Referencing ForAll ThisRecord.Result within Sum and LookUp function

Could anyone help me finding a solution to the problem in a title? Here is a part of code I'm working on. I have no idea why it work in the example marked with yellow and not in cases marked with red.

Thank you in advance for all the helpZrzut ekranu 2021-07-28 170206.png

1 ACCEPTED SOLUTION

Accepted Solutions
GarethPrisk
Resident Rockstar
Resident Rockstar

Us the "As" operator to disambiguate your loops. Since you have nested loops, the ThisRecord will only reference the inner-most loop.

https://powerapps.microsoft.com/en-us/blog/formulas-thisrecord-as-and-sequence/

 

View solution in original post

3 REPLIES 3
MrDzem
New Member

If I try doing it within one loop the result is the same. I split it trying to look for solutions

GarethPrisk
Resident Rockstar
Resident Rockstar

Us the "As" operator to disambiguate your loops. Since you have nested loops, the ThisRecord will only reference the inner-most loop.

https://powerapps.microsoft.com/en-us/blog/formulas-thisrecord-as-and-sequence/

 

View solution in original post

MrDzem
New Member

Thank you so much, it did the job! So simple...

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!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (1,953)