Skip to main content

Notifications

Power Automate - General Discussion
Suggested answer

Array elements and integer index issue

(0) ShareShare
ReportReport
Posted on by 12
Hi all - I was trying to follow this link and here is the error I am getting and I don't know how to fix it because I don't know integers and arrays very well. Unable to process template language expressions for action 'Condition_2' at line '0' and column '0': 'The template language expression 'empty(triggerBody()?['@removed']?['reason'])' cannot be evaluated because property '@removed' cannot be selected. Array elements can only be selected using an integer index. Please see https://aka.ms/logicexpressions for usage details.'.
 
Here is my flow. Thank you in advance! 
 
Categories:
  • CU16121926-0 Profile Picture
    CU16121926-0 12 on at
    Array elements and integer index issue
     
    If people are removed, I dont want them added to a team though. It has to be only when they are added hence the conditions
  • Suggested answer
    SudeepGhatakNZ Profile Picture
    SudeepGhatakNZ 14,234 on at
    Array elements and integer index issue
    This works for me.
     
  • CU16121926-0 Profile Picture
    CU16121926-0 12 on at
    Array elements and integer index issue
     
    Correct. It is a separate private team
  • Suggested answer
    SudeepGhatakNZ Profile Picture
    SudeepGhatakNZ 14,234 on at
    Array elements and integer index issue
     
    Form what I can see you are trying to do is grant access to an user who is added to an Office 365 group to a team. correct?
    Is the Team not connected to the group? Users added to the Office 365 Group should automatically gain access to the corresponding Microsoft Team.
    Is it a private Team you are trying to add the user into?
     
  • CU16121926-0 Profile Picture
    CU16121926-0 12 on at
    Array elements and integer index issue
     
    Thank you! what should the conditions be?
  • Suggested answer
    SudeepGhatakNZ Profile Picture
    SudeepGhatakNZ 14,234 on at
    Array elements and integer index issue
    Please follow this template.
     
  • CU16121926-0 Profile Picture
    CU16121926-0 12 on at
    Array elements and integer index issue
    Hi @SudeepGhatakNZ​​​​​​​
     
  • SudeepGhatakNZ Profile Picture
    SudeepGhatakNZ 14,234 on at
    Array elements and integer index issue
    Can you share the output of the Get group action?
    You can mask the usernames
  • Suggested answer
    CU16121926-0 Profile Picture
    CU16121926-0 12 on at
    Array elements and integer index issue
    Hi @SudeepGhatakNZ​​​​​​​
     
    When I add the "user id" into the field for Get User, it forces it into an apply to each
  • SudeepGhatakNZ Profile Picture
    SudeepGhatakNZ 14,234 on at
    Array elements and integer index issue
    The Get User action should be outside the Apply to each loop.
    You shouldn't require a loop anyway?

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

November 2024 Newsletter…

November 2024 Community Newsletter…

Community Update Oct 28…

Power Platform Community Update…

Tuesday Tip #9 Get Recognized…

Welcome to a brand new series, Tuesday Tips…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 143,867

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 64,174

Leaderboard

Featured topics