0

Struggling with logic

Hi

I have a prototype with 3 checkbox pairs that I've made work like radio buttons (don't ask!)

The default for everything is inactive

Once activated, any checkbox cannot be deactivated unless it's partner in the pair is activated

Each pair has an option for yes and an option for no

I'm setting a variable for each pair depending on what the user selected

This works fine

What I need is that when the user clicks the button, it checks to see if any of the pairs have been left without an option checked.  If that's the case then it'll show an error message.  The error message is a container that is set to hidden by default.

The pseudo logic for this would be:

if (EmailYes = "" || EmailNo = "") {

 show container EmailError

}

I don't know how to test the variables, or how to set the EmailError to show when the button is clicked.

Any help would be much appreciated.

2 comments

Please sign in to leave a comment.