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 Automate / Get value of Choices c...
Power Automate
Answered

Get value of Choices column

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi I would like to Update item of share point by Flow.

The choice column value should be opposite.

 

I wrote the expression as below, but it seems not correct.

Column Type is Yes/No, the other is Choices.

 

If(body('Apply_to_each')?['FilesOtherthanPPT']?['Value'],'Yes'),'No','Yes')

Categories:
I have the same question (0)
  • abm abm Profile Picture
    32,985 Most Valuable Professional on at

    Hi @Anonymous 

     

    It's difficult to give you an answer without a screenshot.

     

    To evaluate the IF condition you need an Equal expression to check the value whether its Yes/No so that it will return the boolean to check against the IF condition.

     

    I think this is what you need

     

    if(equals(body('Apply_to_each')?['FilesOtherthanPPT']['value'],'Yes'),'Value is Yes','Value is No')

     

    Change the Value is Yes and Value is No accordingly.

     

     

     

    Thanks

     

     

  • MattWeston365 Profile Picture
    1,701 on at

    Hi @Anonymous

     

    The first part of the IF expression must always equate to either TRUE or FALSE. You are just missing a comparison expression, so here you could just add equals:

     

    If(equals(body('Apply_to_each')?['FilesOtherthanPPT']?['Value'],'Yes'),'No','Yes') 

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi Thank you for you reply. I still could get the right value.

    I don't know if it is because Column Type is Yes/No, the other is Choices.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi Thank you for you reply. I still could get the right value. I don't know if it is because Column Type is Yes/No, the other is Choices.

  • MattWeston365 Profile Picture
    1,701 on at

    Ah ok, if it's a Yes/No field then you need to test for whether something is true or false, rather than yes or no.

     

    So rather than having 'Yes', change it to true.

     

    If you are dealing with a choice field, then you will need to compare for a string, therefore the format that you're using at the moment is correct.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi I tried this :if(equals(body('Get_items_Review')?['FilesOtherthanPPT']?['Value'], 'True'), 'いいえ','はい')

    'いいえ','はい' is the choices. But it is still not working.

  • abm abm Profile Picture
    32,985 Most Valuable Professional on at

    Hi  @Anonymous 

     

    Add a compose and copy your expression 

     

    body('Get_items_Review')?['FilesOtherthanPPT']?['Value']

     

    This way you can easily evaluate what value is returning using the run history. Then change the value accordingly.

     

    Thanks

     

     

  • abm abm Profile Picture
    32,985 Most Valuable Professional on at

    Hi @Anonymous 

     

    Also I am not sure you need to check true in quotes. It's worth a try without having quotes. Before you do this make sure debug the expression via compose which I mentioned earlier.

     

    Thanks

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi I tried the true, bool(1), bool(Yes),bool(true), but not working.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi I added the compose action and use if(equals(outputs('Compose'), 'Yes'), 'いいえ','はい'), but I still could not get the right result.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Vish WR Profile Picture

Vish WR 873

#2
Valantis Profile Picture

Valantis 813

#3
Haque Profile Picture

Haque 526

Last 30 days Overall leaderboard