Multiselect Lookup Control

Consider the situation where a subgrid of contacts needs to be placed on the Appointments activity form. This would be an N:N relationship between the Appointment and Contact entities. Referring to Figure 1, it’s clear that it’s not possible to create such a relationship

Figure 1

To meet this requirement, one option is to use a Multiselect lookup control. (found in the Field Service managed solution.) Referring to Figure 2, the Contact(s) field is a multiselect lookup control. It works just like a normal lookup and allows multiple contacts to be selected.

Figure 2

The control is defined as a text field (which we’ll go through below) and it stores records as JSON. See below

or

Setup

1.) Create a text field and set it to the maximum character count of 4000.

Figure 3

2.) Add the component ‘Multiselect Lookup Control’

Figure 4

3.) Determine the id of the ‘All Active Contact’ view to be used

Figure 5

4.) Set the control to lookup the contact entity and ‘All Active Contact’ view

Figure 6

Further reading

Form component control

References

https://community.dynamics.com/blogs/post/?postid=a596edbc-bae3-41a5-8148-2f83e8ba8164