Hello all,
I am hoping someone can help me. I have set up a flow based on whether a choice field is changed or not but I am getting an error message. Here is the scenario:
We have set up our Tenders Register in Sharepoint Lists. One of the fields is a choice field called BID STATUS which has five choices ('Go', 'No Go', 'Pending', 'Won', 'Lost', or 'Submitted'). I would like the flow to trigger only if the value of the BID STATUS field is changed to either 'Won' or 'Lost'.
Here is what I have so far:
The Flow Checker is giving me the following error:
When an Item or File is Modified (1)
Fix invalid expression(s) for the input parameter(s) of operation 'When_an_item_or_file_is_modified'.
I am assuming it is something to do with the trigger conditions as I am not sure if I have used the correct syntax. In case you can't see it properly in the JPG, here is what it says:
@or(equals(triggerOutputs()?['body/Bid_x0020_Status/Value'], 'Won', equals(triggerOutputs()?['body/Bid_x0020_Status/Value'], 'Lost'))
Any help would be much appreciated.
Regards,
Bron
Solved! Go to Solution.
Hi @Bron
Thanks for your posting.
Accordingly to your requirement, you would like to filter data based on two conditions (BIDSTATUS = Won or BIDSTATUS = Lost) and currently stuck in expression part.
If you don’t mind, I would like to help you simply your flow without fx and achieve same purpose.
Here is my test SPO list:
Please kindly change condition area as we can add multi-conditions at the same time :
When I tried to add won/lost records in list, I got required email notifications with success.
Hope the information above may help you.
Thanks
Anna
Hi @Bron
Thank you very much for your reply.
Based on your queries , here are the answers for your reference:
1.How do I change the condition to an OR condition?
You can simply click on ‘Add’ bottom and select ‘And row’.
After that, you will be able to see ‘And’/‘Or’ option and set up secondary condition.
2.Once I have done that, do I need to remove the Trigger condition from When an item or file is modified?
Whether you remove trigger condition or not, it doesn’t matter.
If you keep the trigger condition, when status shows any other options, the flow won’t start at the beginning.
If you remove the trigger condition, when status shows any options, the flow goes as normal and navigate to No branch then fails at last. So based on the result, It makes almost no difference.
3.Also, depending on whether the status is LOST or WON, the email needs to go to a different set of people, and contain different information. I don't know if that would require changes to your solution or not.
Currently I know nothing about your result email. I couldn’t tell you that there is absolutely no part that needs to be modified if there are totally different styles for two emails. If you like, you can share me a sample about email.
By the way, the correct fx in your trigger condition should be as below(Seems you missed the Closing bracket. If you are worried about following issues, you can just change fx):
@or(equals(triggerOutputs()?['body/Bid_x0020_Status/Value'], 'Won'), equals(triggerOutputs()?['body/Bid_x0020_Status/Value'], 'Lost'))
Hope the content above may help you.
Thanks
Anna
Thank you for your help Anna. I have made the changes, and will let you know if it works once it is tested.
Regards,
Bron
Hi @Bron
Thanks for your posting.
Accordingly to your requirement, you would like to filter data based on two conditions (BIDSTATUS = Won or BIDSTATUS = Lost) and currently stuck in expression part.
If you don’t mind, I would like to help you simply your flow without fx and achieve same purpose.
Here is my test SPO list:
Please kindly change condition area as we can add multi-conditions at the same time :
When I tried to add won/lost records in list, I got required email notifications with success.
Hope the information above may help you.
Thanks
Anna
Hi Anna,
Thank you for responding. A couple of questions:
Regards,
Bron
Also, depending on whether the status is LOST or WON, the email needs to go to a different set of people, and contain different information. I don't know if that would require changes to your solution or not.
Regards,
Bron
Hi @Bron
Thank you very much for your reply.
Based on your queries , here are the answers for your reference:
1.How do I change the condition to an OR condition?
You can simply click on ‘Add’ bottom and select ‘And row’.
After that, you will be able to see ‘And’/‘Or’ option and set up secondary condition.
2.Once I have done that, do I need to remove the Trigger condition from When an item or file is modified?
Whether you remove trigger condition or not, it doesn’t matter.
If you keep the trigger condition, when status shows any other options, the flow won’t start at the beginning.
If you remove the trigger condition, when status shows any options, the flow goes as normal and navigate to No branch then fails at last. So based on the result, It makes almost no difference.
3.Also, depending on whether the status is LOST or WON, the email needs to go to a different set of people, and contain different information. I don't know if that would require changes to your solution or not.
Currently I know nothing about your result email. I couldn’t tell you that there is absolutely no part that needs to be modified if there are totally different styles for two emails. If you like, you can share me a sample about email.
By the way, the correct fx in your trigger condition should be as below(Seems you missed the Closing bracket. If you are worried about following issues, you can just change fx):
@or(equals(triggerOutputs()?['body/Bid_x0020_Status/Value'], 'Won'), equals(triggerOutputs()?['body/Bid_x0020_Status/Value'], 'Lost'))
Hope the content above may help you.
Thanks
Anna
Thank you for your help Anna. I have made the changes, and will let you know if it works once it is tested.
Regards,
Bron
Hello Ana,
I do the same but when I complete another column, I receive again the mail. I don't know why. I think that this is because the system read again the information.
Could you help me ?
Have a good day.
Vincent.
The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.
Announcing a new way to share your feedback with the Power Automate Team.
Learn to digitize and optimize business processes and connect all your applications to share data in real time.
User | Count |
---|---|
72 | |
23 | |
17 | |
17 | |
13 |
User | Count |
---|---|
125 | |
34 | |
31 | |
28 | |
26 |