Millisecond Forums

Input Participant Generated Answer Into Caption (/question)

https://forums.millisecond.com/Topic17586.aspx

By megangoldring - 11/2/2015

Hi all,
I'm fairly new to Inquisit and cannot figure out how to solve this problem:
I would like for participants to generate a name that I can input later into questions.
For example:
1. What is your child's first name (textbox)
2. How old is <identified child>

Thank you!
By Dave - 11/2/2015

Inserting properties, etc. into captions, text items, etc. generally works like this:

<survey mysurvey>
/ pages = [1=a; 2=b]
/ showbackbutton = false
/ showpagenumbers = false
/ showquestionnumbers = false
</survey>

<surveypage a>
/ questions = [1=name]
</surveypage>

<surveypage b>
/ questions = [1=age]
</surveypage>

<textbox name>
/ caption = "What is your child's first name?"
</textbox>

<textbox age>
/ caption = "How old is <%textbox.name.response%>?"
/ range = (0,120)
</textbox>

And if you additionally want to normalize the input (response), you can apply string functions in an inline expression:

<survey mysurvey>
/ pages = [1=a; 2=b]
/ showbackbutton = false
/ showpagenumbers = false
/ showquestionnumbers = false
</survey>

<surveypage a>
/ questions = [1=name]
</surveypage>

<surveypage b>
/ questions = [1=age]
</surveypage>

<textbox name>
/ caption = "What is your child's first name?"
</textbox>

<textbox age>
/ caption = "How old is <%capitalize(tolower(textbox.name.response))%>?"
/ range = (0,120)
</textbox>