Collecting postcode and date range information

maveral
maveral Lancaster, Lancashire, United KingdomCommunity Member Qubie ✭
edited July 29 in Custom Code

Hello,

As part of my survey, I'm trying to create a format in which participant must enter a postcode (only 5 digits out of 6 because we should not need to know the last digit), start year and end year (as a drop down list). The format I want is as follows.


I checked 'Collecting date of birth in MM/YYYY format' and also checked TomG's reply. I can't use both in this scope. Below I found an example from the Qualtrics library that is very close to what I want, but unfortunately it is not possible for me to change the example at all.

Participant can generate 5 different entries at once (please see first image), so I thought a format similar to the one in the library would be best. I really need your help and I would really appreciate it if you could help me with this.

PS: I have almost no JS coding knowledge (but I can try my best) and am very new to Qualtrics platform. I also tried to change the JS codes of the example in the library but it was not possible. Even if I change the dates in the code, the dropdown list does not change.

Best Answers

  • ahmedA
    ahmedA IndiaCommunity Member, XMPN Member Wizard ✭✭✭✭✭
    Accepted Answer

    Use a side by side question. First column text enty, validation to check for numbers min 11111 max 999999.

    In the other two columns, enter the years as answers and then change the format to dropdown.

  • ahmedA
    ahmedA IndiaCommunity Member, XMPN Member Wizard ✭✭✭✭✭
    Accepted Answer

    You may also add an additional validation to check that end year is greater than start year.

  • ahmedA
    ahmedA IndiaCommunity Member, XMPN Member Wizard ✭✭✭✭✭
    Accepted Answer

    Revert to select one, then change the options,then switch to drop down.

Answers

  • maveral
    maveral Lancaster, Lancashire, United KingdomCommunity Member Qubie ✭
    edited July 21

    Hi Ahmed,

    Thank you very much for your answer. I chose dropdown for the second and third parts (for the dates) and it looks perfect but as you can see in the picture below, I couldn't change the answers. There are just Answer 1 and Answer 2. How can I add years to the dropdown list (from 1950 to 2021)?

  • maveral
    maveral Lancaster, Lancashire, United KingdomCommunity Member Qubie ✭

    Hi Ahmed,

    Thank you very much for your prompt reply. Now I can see all the dates in dropdown list.

    I would be very grateful if you could help me with one last thing. You previously mentioned about validation check.

    When I activate Add validation switch on the left menu bar, Custom Validation window appears. And when I click Select Choice dozens of dates appear from 1950 to 2021 (as in the picture below). How can I add an additional validation to check that end year is greater than start year?

  • ahmedA
    ahmedA IndiaCommunity Member, XMPN Member Wizard ✭✭✭✭✭

    Hmm...based on your screenshot, it appears that adding such a validation may not be possible without using JS.

  • maveral
    maveral Lancaster, Lancashire, United KingdomCommunity Member Qubie ✭
    edited July 21

    Hi Ahmed,

    Thank you for your reply and time.

    Can you at least guide me on how I can learn JS for this specific template?

  • ahmedA
    ahmedA IndiaCommunity Member, XMPN Member Wizard ✭✭✭✭✭

    I had posted an answer related to two matching dates. It usually uses jquery date picker. So, search the community and you'll find the answer.

Sign In to Comment

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!