Pref-filled answers
Last updated
Last updated
(c) 2024 Data Illusion Zumbrunn. All rights reserved. Reproduction strictly forbidden.
Pre-filled answers allows you to create a deployment link URL that will pre-fill your survey with specific values. Once you share this link with your respondents ngSurvey will pre-fill the survey with the values that have been set in this link to select questions or fill fields.
You may either create manually pre-filled links or you can use the preview / testing center to generate the link dynamically while you fill out the test survey.
You may also set the default text value on your answer properties to set a default text that will fill your fields on the first time your respondents take the surveys.
To generate dynamically the link while you select the answers make sure to enable the generate pre-filled answers url property of the preview / test center. Once its enabled you will be able to see and copy the pre-filled link from the preview navigation toolbar.
ngSurvey will automatically build the link based on your actual test survey selections and entries.
Advanced users may use the web link and append manually the values that should be used to pre-fill the survey.
Values should be added as a querystring name / value pair with following format
a_fieldansweridtofill=yourvalue q_questiontoselect=answeridtoselectforthatquestion
In the sample below ngSurvey would
fill the survey answer field having an id of MBs6BnWERPH69EIEZiba with a value John.
select the question with id MBs63pNZnnxG7ctdYfIa with the answer having an id of MBs63pNZnnxG7ctdYfJa
You may find the answer id in the browser URL when you edit the answer properties
The question id can also be found in the browser url when you edit the question properties.