Is it possible to generate a unique code for every person that completes my survey?

  • marcospierolads
    Asked on June 30, 2019 at 2:13 AM

    Hello,

    I am creating a market research survey that I intend to put on Amazon MTurk. Whenever a worker (Turk) completes my survey, I'd like to customize the 'Thank you' page (or some section at the end) to include a unique code the worker can then paste on their MTurk dashboard to certify that they have completed my survey. This code should change every time the form is filled out so I can keep track of whom I should pay.

    Is there any way to do this with JotForm?

    Thanks a lot in advance for your support.

    Best,

    Marcos

  • jherwin
    Replied on June 30, 2019 at 8:29 AM

    You can try our "Random Value Generator" widget, it has an option to generate unique codes for each submission. You can also include that "random value" to your thank you page.

    Please check my screenshot below for reference:
    Is it possible to generate a unique code for every person that completes my survey? Image 1 Screenshot 30Is it possible to generate a unique code for every person that completes my survey? Image 2 Screenshot 41
    Guide: How-to-Add-a-Widget-to-Your-Form

  • marcospierolads
    Replied on July 2, 2019 at 1:45 AM

    Hi Jherwin,

    Thank you for your response.

    I can't see the 'Thank you page' section from step 2 in your screenshot. Is this an error?

    Is it possible to generate a unique code for every person that completes my survey? Image 10

  • jherwin
    Replied on July 2, 2019 at 3:04 AM

    You are using card forms, please follow this guide on how to locate your thank you page: How-to-Edit-Thank-You-Page-Settings.

    Place the unique name of "random value generator" widget to your thank you page:
    1562050925typeA Screenshot 10
    Here is the result:
    1562050989random Screenshot 21

    To find the unique name of your widget, please refer to this guide: How-to-Find-Field-IDs-and-Names

  • marcospierolads
    Replied on July 2, 2019 at 3:32 AM

    Thank you for your prompt response.

    I've tried doing this but the generated random number doesn't show up. Instead, the unique name of 'Random Value Generator' simply disappears. Why does this occur? I'm attaching two screenshots so that you can see if I made any mistake.

    Thanks again.

    ----------

    Settings:

    Is it possible to generate a unique code for every person that completes my survey? Image 10

    Result:

    Is it possible to generate a unique code for every person that completes my survey? Image 21

  • jherwin
    Replied on July 2, 2019 at 5:00 AM

    Let me run a few tests and get back to you with relevant information.

    Thank you for your patience.

  • marcospierolads
    Replied on July 3, 2019 at 12:30 AM

     Hello,

    I created a new form to run some experiments, and I've now found a solution. I'll share it here in case anyone trying to do the same finds this thread.

    ---------

    Ok so, apparently, if 'Hide field' is 'ON' for the 'Random Value Generator' widget, the widget will not generate any value (that's why in the second screenshot of my last response {typeA} 'disappeared'. It turns out, it didn't really disappear, it's just that there was no value to show.)

    So, to fix this, one should click on 'Widget Settings' for the 'Random Value Generator' and select 'Yes' below the 'Run in the background option'. This will achieve a similar effect to the 'Hide field' setting. The field will not be shown to anyone filling the form, but the random value will still be generated.

    1562127147s1 Screenshot 10

    You can then proceed as instructed by Jherwin before. Simply click on the gear icon ('Properties') from the 'Random Value Generator' field. Then, go to the 'Advanced' tab and there expand the 'Field Details' section to copy the field's unique name (which, in my case, was {identifierCode}. (REMINDER: Make sure 'Hide field' is OFF.)

    1562127605s2 Screenshot 21

    Finally, if you're using card forms, scroll down to the bottom of the form builder, click on 'Edit Thank You Page' and paste the unique field name you copied wherever you want it to appear.

    1562127878s3 Screenshot 32

    That's all, the field's unique name will be replaced by a generated value from the 'Random Value Generator' widget when someone submits a response to your form.

    I hope this helps.

  • jherwin
    Replied on July 3, 2019 at 1:39 AM

    Thanks for the detailed instruction @marcospierolads - We're glad that you are able to fix the issue you're experiencing. Thank you for sharing how you found the solution as well. I'm sure the guide you shared to us will help other users with the same requirements as yours.