As part of the form designer you can create questions that are recorded as part of the form response, but are not mapped directly to fields in Dynamics 365. This article will focus on creating and customizing these questions.
1. Under Add Controls (Unmapped) use the drop down to select the field type.
2. Click Add Control
3. Next to the Control that appears under the section click Edit to customize
4. Customize the Question as Needed
- Question Label - Enter the question text to display to end users
- Required - Yes means the customer must provide an answer. No means the customer may leave the question blank
- Hidden - Yes will remove the question from view, No will allow the question to be seen
- Required Message - If the question is required include a validation message to display if the customer tries to continue without answering the question.
- Format - select for a quick fill of formatting validation if desired, Leave as custom to leave blank or to create your own.
- Format Expression - if you want to enforce specific formatting include the Regex here.
- Format Message - Provide users with the required format if they fail to meet it.
Under Advanced Settings
- Match Mapped Entity - Field For use with stand alone forms only. You can set a question to map to an existing record in CRM rather than creating new data. For example if you have a stand alone form and you ask for name, and email address, you can set the email address question to Yes on this field and it will link the form to the existing contact. Each Question which has Match Mapped Entity set to true is used as part of the query that looks up the entity.
For example, let's say you have a Form for a Contact which has "First Name", "Middle Name", and "Last Name" all set as Mapped Questions, but only the First Name and Last Name question has "Match Mapped Entity" set to true. If a user fills out this Form, setting First Name to "John", Middle Name to "Jacob", and Last Name to "Smith", then when the Form Response is completed, the system will query for Contact records with First Name = "John" and Last Name = "Smith". If it finds an existing Contact, then it will set Middle Name to "Jacob". Otherwise, if it cannot find an existing Contact, then it will create a new Contact record whose First, Middle, and Last name are "John", "Jacob", and "Smith" respectively.
As another example, if you have a Form for a Contact with a mapped question for Email that has Match Mapped Entity set to yes, then when the system goes to query for existing Contact, it will try to find an existing Contact with the same Email as the value entered on the Form by the user. If the system doesn't find such a Contact, it will create a new Contact instead.
- Submitted by Contact Field - Field For use with stand alone forms only. This setting kicks in when the Form is mapping back to a lookup field. If the question on the Form does in fact map back to a lookup field, then one of two values will be mapped back:
If the Submitted by Contact field is set to true, then the mapped back value is the Form Response's Contact field, which is set to whoever submitted the Form.
Otherwise, the mapped back value is whatever value was entered into the lookup question
- Page Section - By default will be on the first page section but can be adjusted if there are multiple sections
- Question Sort Order - Set the order the questions will display in
5. Add Answers to Question Types if Applicable
To add your answers click Add Answer to get a new item in the grid. You can set a Name and Value (these can be the same or different but the name is what will display to customers).
Once you've added your values click Save to save the answer.
*Note if you don't save each answer, and only click Save Question, the answers will not be saved.
6. Click Save Question
The question text should display under the section identified in the customization.