Creating Dependent Dropdown Lists
The following procedures provide high-level steps for creating dependent dropdown lists. To understand the process, you should be familiar with creating custom lists, custom record types, and custom transaction types.
For a detailed example, see Dependent Dropdown Lists Example.
To create a field that is filtered by multiple other List/Record fields, complete the following steps:
Creating the Custom Lists and Custom Record Type
To understand how the feature works, it helps to think in terms of controlling fields versus dependent fields. Controlling fields are used to determine the selections that are available in dependent fields. For example, you could have Shirt Color and Shirt Size controlling fields and a Shirt Style dependent field. The style of shirt available depends on the color and size selected.
Before you can create fields that filter based on selections you make in other fields, you first must create a custom list for each controlling field. Then you create the custom record type for the dependent field. You use these custom lists and custom record when you create the fields to include in transaction types or other record types.
To create the custom lists and custom record type:
-
Create a custom list for each controlling field.
-
Create a custom record type whose field provides the options to be available in the dependent field. The custom record type must contain List/Record fields that reference the custom lists you created for the controlling fields in the preceding step.
-
Create a custom record instance for each option you want to be available in the dependent field.
Creating Custom Fields and Setting up Filtering
Next you use the custom lists and custom record created in the preceding procedure to create and add custom fields to the transaction type or other record type. Using the shirt example, you'd create fields for Shirt Color, Shirt Size, and Shirt Style and apply them to Sale Item. You configure the filtering options on the dependent field, in this case Shirt Style.
To create custom fields and set up filtering:
-
Create a custom field of the List/Record type for each controlling field.
-
For the dependent field, create the same type of List/Record custom field that you created for the controlling fields in the preceding step.
In the List/Record field, select the custom record type you created in Step 2 of Creating the Custom Lists and Custom Record Type.
-
Click the Sourcing & Filtering subtab. Complete the following:
-
In the Filter Using column, select one of the controlling fields.
-
In the Compare Type field, select the qualifier you want to use to determine the filtering. For example, if you want the selections in the fields to match, select equal.
-
In the Compare To column, select the field on your custom record type that refers to the field you selected in the Filter Using column.
-
Repeat these steps for each controlling field.
-
Click Save.
-
You can create multiple layers of dependencies. In the Shirt Style example, you could have another field that is filtered based on your selection in the Shirt Style field. You must create a custom record type for each additional dependent field in the same way you created the Shirt Style custom record type.