How to conditionally end an online experiment in PsychoPy with Pavlovia surveys

Hello

I had a similar problem. The participants have to agree to the GDPR, otherwise they cannot participate. My survey is included in a PsychoPy experiment, so I get the relevant information from the survey with a code component. The survey component is called demo.

Begin Experiment

VPn = " ";
VPCode = " ";

zuStimmung = " ";

Begin routine

VPn = expInfo["participant"];
surveyResp = demo.getResponse();
VPCode = surveyResp["VP-Code"];

zuStimmung = surveyResp["ZustimmungDatenschutz"];

if ((zuStimmung === "FALSE")) {
    quitPsychoJS('Vielen Dank für Ihr Interesse', false);
    psychoJS.setRedirectUrls("https://www.uni-muenster.de/Psychologie/", "https://www.uni-muenster.de/Psychologie/");
}

If you are only using a survey, create a logical expression on the Survey Logic tab and close the survey.

grafik is the survey “equivalent”.

Best wishes Jens