@simms7400
In my humble opinion the best way to ensure a valid selection is made would be to prevent the user from making an invalid selection. For example, suppose you have a collection like this
ClearCollect(
myCollection,
{Value: "Option 1"},
{Value: "Option 2"},
{Value: "Option 3"},
{Value: "Not Applicable"}
);
Now create a new ComboBox with these properties
Items: myCollection
DisplayFields: ["Value"]
You can prevent the user from selecting Not Applicable when another Option is already selected and vice versa by putting this code in the OnChange property of the ComboBox.
If(
"Not Applicable" in ComboBox1.SelectedItems.Value,
ClearCollect(myCollection,{Value: "Not Applicable"}),
If(
IsEmpty(ComboBox1.SelectedItems.Value),
ClearCollect(
myCollection,
{Value: "Option 1"},
{Value: "Option 2"},
{Value: "Option 3"},
{Value: "Not Applicable"}
),
Remove(myCollection,{Value: "Not Applicable"});
)
);
Give this method a try for yourself in a Test Application. I think you'll like it!
---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."