psychopy.org | Reference | Downloads | Github

Textbox component not saving typed response

I am trying to get people to type in emails so I have created a textbox component that reads ‘type email here’. However, after typing the email, the output data is just saving the ‘type email here’ string and not what was typed.
I followed every step from https://www.youtube.com/watch?v=a9xQlFx5dOQ but nothing has worked.
Here is my project:
https://pavlovia.org/ben.muzekari/neuroperfect

Any help would be great, thanks!

Hi There,

I can’t seem to access your project when I click the link - is it set to public? if not you may have to change that setting before we can access it :slight_smile:

You can actually access the demo from that youtube video here if helpful https://gitlab.pavlovia.org/Hirst/textboxdemo

Becca

Hi Becca,

Sorry about that! Here it is again: https://gitlab.pavlovia.org/ben.muzekari/neuroperfect

It should be public now. And thanks I will take a look :slight_smile:

I have taken a look and I can’t seem to spot any major discrepancies between mine project and the demo. Although, mine I am trying run online via Pavlovia but I don’t think that should matter. Can you spot any key differences that may be contributing to the problem?

hi steve - I keep getting a 404 page not found error - please could you double check your privacy settings? alternatively you can ad me as a member to the project whilst I take a look (username is lpxrh6)

Becca

Strange. I have added you as a member!

OK try this. add a code component to your routine where you have the textbox. Then in the ‘endRoutine tab’ enter the following:

thisExp=psychoJS.experiment;
thisExp.addData('this text', textbox_email._pixi.text);

This will save a column in your output file with the header ‘this text’ (change as you wish) and the value of the typed response.

Hope this helps,
Becca

PS. for future users ‘textbox_email’ is the name of the texbox component used

1 Like

Works perfectly :slight_smile: Thank you!

woo! pleased to hear

Becca

@Becca hello! my experiment has 5 sections and in all, I am using the textbox component. In the introductory section and the 2nd part, the textbox component is storing the data perfectly. The remaining columns are blank. I am using image stimuli for the 4 main routines. all of the routines are linked to the same csv file. your help will be appreciated :slight_smile:
Plus unlike the introductory video, you have posted for the textbox component I was unable to use the mouse stimuli because my experiment crashes. I even tried to use the routines from the GitLab you have uploaded. As a solution, I have used the ‘right’ key to submit the response. I hope this is not leading to the issue. If there is a solution for the same let me know. My mouse component works perfectly if i just have to click anywhere on the screen but if it has to click on a particular variable it crashes.

Hi There!

It sounds like there might be a few elements to this (textbox issues, mouse issue) - please could you start a new thread so that we can address these individually? It would be great if you could please provide more info such as the version of PsychoPy you are currently using and if you face the problem locally, online or both - thanks!
Becca