Setting a global variable based on radio button select

Hi
First - i am using custom radio buttons for this.

Here’s the problem.

I am creating a funnel and I start off with a question with multiple choices

Depending on the selection, the user will see different questions further down the funnel.

So, if you select choice 1 you will see questions 2, 3, 4a, 5
But, If you select choice 2 you will see questions 2, 3, 4b, 5

I am trying to set a variable based on if the user selects choice 2. So that when you get to question 3 and click next you will be diverted to question 4b rather than 4a.

But I am having trouble making this happen. I can’t tell if I am setting the value of the variable wrong or setting the onclick event wrong.

If you could post your .rp file, or a similar sample, it will help forum folks help you faster.

This sounds like a fairly common type of flow and can certainly be done in Axure. To help with debugging, you can click the Console button in your prototype HTML (published prototype or Preview) —all the way over on the left in the browser frame. Then you can see the status of all your global variables and all the events as they occur, like button clicks, hovers, etc.

I think you could do it with a variable and a conditional action

Set a condition on the radio button such that if ‘yourVariable’ equals ‘A’ then set text of question 4 to “the text you want for scenario 4a” else if set text of question 4 to “the text you want for scenario 4b”

On clicking radio button 1 set value of ‘yourVariable’ to A
On clicking radio button 2 set value of ‘yourVariable’ to B

So - I ended up figuring it out but let me try to best describe what I did.

If the user selected a particular answer on question 1, it set the value of a global variable to “1234”.
That global variable then set a field value found on question 3 (it was hidden out of view). If the user clicked the next button and the value in the field matched “1234” it would go to question 4a. If it did not match that number, it would go to question 4b.

Not sure if that was the most efficient way to do it, but it worked.

Thanks for everyone’s help!

D