| Reference | Downloads | Github

Displaying text boxes only under certain conditions

If this template helps then use it. If not then just delete and start from scratch.

OS (e.g. Win10):
PsychoPy version (e.g. 1.84.x):
Standard Standalone? (y/n) If not then what?:
What are you trying to achieve?:
I have to textboxes in my encoding phase. One box has accept/reject and the other textbox has acknowledge/invalid. In my excel sheet, I have a column labelled VoluntaryMandatory. I want it so that when the excel sheets loads voluntary into the experiment, I have only accept/reject show up on the screen, but when it loads Mandatory, I want acknowledge/invalid to show up on the screen.

How can I achieve this?

Rather than displaying different text boxes, why not use the same text boxes but change their contents? You could have a column for accept/acknowledge (let’s call it affirmativeText) and one for reject/invalid (let’s call it negativeText) in your Excel file, then just set the text parameter of your textboxes to Set Every Repeat with the values being $affirmativeText and $negativeText

1 Like

That works, that is the solution I came up with, except that lining up the words is difficult because accept and acknowledge are different word lengths.