As the title implies, my customized Sharepoint form is using multiple dropdowns for data entry. I'm trying to validate the form to ensure that at least one of these dropdowns is not empty. This formula works for ONE dropdown:
If(IsBlank(Dropdown1.Selected.Value), Notify("You must fill out of one the dropdowns", NotificationType.Error,3000), SubmitForm(SharePointForm1))
However, if I modify it to this:
If(IsBlank(Dropdown1.Selected.Value) Or IsBlank(Dropdown2.Selected.Value), Notify("You must fill out of one the dropdowns", NotificationType.Error,3000), SubmitForm(SharePointForm1))
it's wanting to have both dropdowns (Dropdown1 and Dropdown2) to have value before it submits.
Solved! Go to Solution.
Thanks for the suggestion, but doesn't the 'And' operator (instead of 'Or') imply that both dropdowns need to have value? I want the form to validate as long as there is at least one dropdown that is not blank.
If( !IsBlank(Dropdown1.Selected.Value) Or !IsBlank(Dropdown2.Selected.Value),SubmitForm(SharePointForm1), Notify("You must fill out of one the dropdowns", NotificationType.Error,3000) )
Isn't that what the AND statement says, if both are blank, then send the notification, otherwise submit the form.
Ok, I was thinking of this: !IsBlanlk(....). I tried your suggestion it and it works. The whole time I had the conditions backwards! Thanks for your help. Will mark your answer as the solution.
Check out the News & Announcements to learn more.
Please join us on Wednesday, October 20th, at 8a PDT. Come and learn from our amazing speakers!
Check out the new Power Platform Community Connections gallery!
Congratulations, the new Super User Season 2 for 2021 has started!
Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.