This article explains how to allow the user to select an answer from a fixed list, originating from an external data source, in the response form so it can be used to populate the smart template.
Prerequisites
|
How to allow selecting an answer from a fixed list
When building the response form, the Data connector question can be used to allow the user to pick from an existing list of answers originating from an external data source. It can be created by following the steps below:
- In Template Designer, open the Form tab.
- Click + Add question.
- In the Type field select Data connector.
- In Question title type the question. This is the question that will be displayed to the end-user.
- Select the External data source containing the list of answers necessary for the question.
- Select the Label column of the data source that should be displayed to end-users when answering the question.
Important
The Label column of a Data connector question will only display String values.
In the example below this means that only the fields marked green are shown in the Label column dropdown. The fields marked red are not shown because these are Number and DateTime fields. However it is possible to use different value types by using the form responses or external data smart fields.
- Optionally, set additional settings:
- Required: Enable this option if the user should be prevented from finalizing the generation of the document if the input is missing. An asterisk will be displayed in the response form to indicate that the question is mandatory.
- Hint text: Prepopulate the question to guide the user when filling in the response form. The hint text will be deleted when the user starts typing in the field.
- Reference name: Will be prepopulated based on the question title. The reference name will be displayed when using the form responses and is also the name used in the binding syntax.
- Prefill text: Prepopulate the question with a default value to guide the user when filling in the response form. The prefill text can be edited.
- Spacing before: Edit the space between the question and the elements above it in the response form (None, Medium, or Large).
- Spacing after: Edit the space between the question and the elements below it in the response form (None, Medium, or Large).
- Helptext prefix: Add additional help text above the question to guide the user.
- Helptext postfix: Add additional help text below the question to guide the user.
- Share value: Enable this option if the same question is used in the response form of dynamic text elements or slides that can be inserted when generating a document or a presentation. The answer to the question will be reused to avoid prompting the user with redundant questions.
- Click Add to form.
Tip
Once the question has been created you can click Preview form to see how the question will appear to the end-user.
Example
Selecting the name of an airport stored in the external data source Airports.
In the example this external data source is used:
Create a Data connector question with the Question title 'Airport', and link it to the External data source Airports and Label column 'Name':
In the Composer the result looks like this:
Comments
Article is closed for comments.