Automate object visibility and value
For all field objects, data controls, and static objects, Claris Studio provides automations that allow you to conditionally set the visibility of the object, its value, or both. For example, you could set a short text object to appear after the 'Other' option is selected from a single choice field to allow a user to enter their own value.
To set automations for an object:
-
In a form or list-detail view, add an object.
-
Select the object, then do one of the following:
-
Click
in the top right corner of the object.
-
In the Properties pane on the right, click the Automation tab, then click
next to Visibility or Value.
-
-
In the Object Actions dialog that appears, you can set conditions for both the visibility and value of the object, or both. There are two methods for doing so: Field conditions and Calculations.
Field conditions
Use the Field conditions option to set the visibility and value of an object based on the values of other objects using common 'And When' and 'Or When' logic.
-
Select the Field conditions option at bottom of the dialog, then choose whether you want to control the visibility of the object (Show/Hide tab) or the value of the object (Value tab).
Note You can set separate conditions for both Show/Hide and Value.
-
Choose an action to be performed whenever the conditions are met. For Show/Hide, the available choices are:
-
None
-
Hide this object
-
Show this object
For Value, the available choices are:
-
None
-
Set the value
-
-
Configure the When condition by first selecting a field from the list. The fields you see are the fields present in the table used for the view.
-
Set the condition for the field. The available conditions depend on the selected field.
-
Set the value of the field. Depending on the selected field, you can either choose an option from a list or input a value.
-
Additionally, you can narrow the condition by clicking + And When, broaden the condition by clicking + Or When, or use a combination of both. Follow the previous steps to set the additional conditions.
-
Click Apply when finished.
Now, the chosen action will be performed whenever the conditions have been met for the selected field.
Calculations
For more advanced cases, you can use the Calculation option to set the visibility and value of an object using a calculation. For Show/Hide, the calculation should evaluate to a Boolean (true/false) value, and for Value, it should evaluate to the default field value. See Primer for Claris Studio calculations.