Branch issues


Author
Message
linatet
linatet
Respected Member (462 reputation)Respected Member (462 reputation)Respected Member (462 reputation)Respected Member (462 reputation)Respected Member (462 reputation)Respected Member (462 reputation)Respected Member (462 reputation)Respected Member (462 reputation)Respected Member (462 reputation)
Group: Forum Members
Posts: 17, Visits: 78
Hi, I am trying to show "inst1", then "english". If participants do not answer they know English, they should be redirected to an end page. If they check they know English, they should be directed to "survey.demo". Afterwards, they should see "inst_cont". However, the branch is not working as after "english", participants see inst_cont regardless of the answer. I have tried doing the same with numbers (eg. english.response <=4) and correct.response, with no success. This is an excerpt of the relevant code part:

<survey inst>
/pages=[1= inst1; 2= english]
/ branch = [
if (radiobuttons.english.response == "Neither good nor bad" ||
radiobuttons.english.response == "Slightly good" ||
radiobuttons.english.response == "Moderately good" ||
radiobuttons.english.response == "Extremely good"
) survey.demo else surveypage.end
]            
</survey>

<survey inst_cont>
/pages= [
    1=inst2; 2=inst3; 3=inst4; 4=inst5]
/ finishlabel = "Yes, I agree to participate in this study."
</survey>


<expt>
/subjects = (1 of 2)
/groupassignment = groupnumber
/blocks = [
    1= inst;
    2= inst_cont;
    3= demo;
    4= rf_inst;
    5= RegulatoryFocus;
    6= demo3;
    7= between;
    8= pos_neg;
    9= final;
]
/onexptend = [values.completed = 1]
</expt>

<surveypage english>
/ fontstyle = ("Arial", 3%, false, false, false, false, 5, 1)
/subcaptionfontstyle = ("Arial", 1.5%, false, false, false, false, 5, 1)
/itemfontstyle = ("Arial", 3%, true, false, false, false, 5, 1)
/responsefontstyle = ("Arial", 2.5%, false, false, false, false, 5, 1)
/questions = [1 = english]
/showpagenumbers = false
/showquestionnumbers = false
/ showbackbutton = false
</surveypage>

<radiobuttons english>
/caption = "How would you describe your proficiency with the English language?"
/ options = ("Extremely bad", "Moderately bad", "Slightly bad",
"Neither good nor bad", "Slightly good", "Moderately good", "Extremely good")
/ optionvalues = ("1", "2", "3", "4", "5", "6", "7")
/required = true
/orientation = vertical
</radiobuttons>

Thank you so much for the prompt response!!

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Threaded View
Threaded View
linatet - 4 Years Ago
Dave - 4 Years Ago

Reading This Topic

Explore
Messages
Mentions
Search