For Drop-down list, Radiobutton list, Checkbox list and Multichoice fields, the form developer specifies option lists. Sometimes, we don’t want all options to be available all the time. ActiveForms allows you to change option lists dynamically, in accordance with to data entered by a user in the form.
The option table for a field includes two columns: Initial state and Action:
Initial state specifies whether the option is initially (when presenting the form) visible and active. Action tells us when this state is to change.
By default, all options of all fields are visible and active. However, when building a logical condition, you can decide when an option should be hidden or disabled. For example, you can restrict a list of available credit cards depending on income specified by a user:
You can build conditions in both directions, i.e. you can specify:
An option can be visible and active depending on values entered in other fields, but you are free to base those conditions on hidden fields whose values will be passed via an URL or the API. This way, using form calling parameters, you can influence options that should be displayed to a specific user.
This mechanism works perfectly when the number of dynamically enabled options is not very large. If you want to build long and very variable option lists, consider generating options by external services.