Forum Discussion
how to add an OR statement to formula
Hi,
Looking for some help on this formula:
Formula suggested by Rob_Elliott should work for you.
However, And and Or function already returns true/false result. Hence, no need to use If function. Use shorter formula like:
varTabSelected=1 && (DataCardValue71.Selected.Value = "Diversion" || DataCardValue72.Selected.Value = "Diversion")
OR
And(varTabSelected=1, Or(DataCardValue71.Selected.Value = "Diversion", DataCardValue72.Selected.Value = "Diversion"))
Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.
- Rob_ElliottBronze Contributor
RenPNW the syntax needs to follow the following pattern:
If(
And(
Or(
cb1.Selected.Value = "Diversion", cb2.Selected.Value = "Diversion"),varTabSelected=1),
true, false)Rob
Los Gallardos
Microsoft Power Automate Community Super User.
Principal Consultant, SharePoint and Power Platform WSP Global (and classic 1967 Morris Traveller driver) Formula suggested by Rob_Elliott should work for you.
However, And and Or function already returns true/false result. Hence, no need to use If function. Use shorter formula like:
varTabSelected=1 && (DataCardValue71.Selected.Value = "Diversion" || DataCardValue72.Selected.Value = "Diversion")
OR
And(varTabSelected=1, Or(DataCardValue71.Selected.Value = "Diversion", DataCardValue72.Selected.Value = "Diversion"))
Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.