web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Get Value of Parent Fo...
Power Apps
Unanswered

Get Value of Parent ForAll

(0) ShareShare
ReportReport
Posted on by 8

I'm working within a ForAll, and Attempting to UpdateIF, however in the UpdateIf Statement, I don't have Access to "ThisRecord.EmailAddress" from the ForAll.  Is there a way to reference ThisRecord in the Nested UpdateIf?

 

ForAll(Collection1,

If(CountRows(UpdateIf('SharePointList',StartDate = StartDate1,
{Title: Office365Users.UserProfile(ThisRecord.EmailAddress).Mail})) > 0,"Exist","Doesn't Exist");

 

 

Categories:
  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @IceCat 

    Please consider changing your Formula to the following:

    ForAll(Collection1 As _col,
     If(
     CountRows(
     UpdateIf('SharePointList',
     StartDate = StartDate1,
     {Title: Office365Users.UserProfile(_col.EmailAddress).Mail}
     )
     ) > 0,
     "Exist",
     "Doesn't Exist"
    );

    Now, that said...you have some issues with your formula in general.

    1) You are counting the rows of the UpdateIf...UpdateIf returns the full table of records from the datasource.  So, you will never have a your false condition ("Doesn't Exist") as you will never get 0 back.

    2) Your ForAll will be returning a single column Table of Values.  You will end up with a table with as many rows in your Collection1 and each value will be "Exist".

    3) I assumed StartDate1 was some other variable and not in your collection.

     

    So, I would review the above to determine what you are really trying to do.

     

    I hope this is helpful for you.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 397 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 354

#3
WarrenBelz Profile Picture

WarrenBelz 232 Most Valuable Professional

Last 30 days Overall leaderboard