Thank you for your feedback.
Form temporarily unavailable. Please try again or contact docfeedback@servicenow.com to submit your comments.

Screen UI policies for the mobile app

Log in to subscribe to topics and get notified when content changes.

Screen UI policies for the mobile app

Use screen UI policies to control which field is mandatory or visible in ServiceNow Agent. With screen UI policies, you can improve screen readability, which helps your users find the information that they need to do their tasks more efficiently.

Screen UI policies are similar to the UI policies that are used on forms in the instance, but screen UI policies are designed for the mobile app. Policies contain a set of conditions that you can use to determine when the policy applies. When a screen UI policy is triggered by a condition that you defined for the policy, all UI policy rules that are associated with that policy are applied.

Differences from UI policies for forms

Screen UI policies are similar to the UI policies that are used on forms with the following exceptions:
  • Screen UI policies cannot control whether a field is read-only.
  • Screen UI policy conditions cannot be scripted.
  • Reference and date/time field types cannot be used in screen UI policy conditions.

Create a screen UI policy for the mobile app

Create screen UI policies to dynamically change which fields are mandatory or visible on screens in the ServiceNow Agent mobile app.

Before you begin

Role required: ui_policy_admin or admin

About this task

A screen UI policy condition evaluates all fields on a table even if they are not visible on the screen.

Procedure

  1. Navigate to System Applications > Studio.
  2. In the Select Application pop-up window, select your mobile app.
  3. In the Application Explorer pane, point to Mobile Development > UI Policies and click the pop-out icon(pop-out icon.).
  4. On the Screen UI Policies list, click New.
  5. On the form, fill in the fields.
    Table 1. Screen UI Policy form
    Field Description
    Name Name of the screen UI policy.
    Short description Short summary of the screen UI policy.
    Order Processing sequence, from the lowest to the highest number. If two policies conflict, the screen UI policy with the higher number executes.

    For inherited UI policies, the extended (child) table UI policies are executed first. Next, the base table UI policies are executed from the lowest to the highest specified value.

    Table Table for the screen that you want to modify.
    Condition Conditions that must be fulfilled to apply this screen UI policy. Conditions are built with the condition builder. For details about this tool, see Condition Builder

    The instance only rechecks if a user manually changes a field on a screen. If a UI action or context menu action makes a change, or a user makes a change from a list, the instance does not evaluate these changes.

    Reverse if false Option for specifying that the screen UI policy action should be reversed when the conditions of its policy evaluate as false. When the conditions are true, actions are taken and when they change back to false, the actions are reversed (undone).
    Active Option for enabling the screen UI policy.

Example: Use a screen UI policy when the state field is not On Hold

This example shows how you can configure a screen UI policy to apply on screens that use data from the Incident [incident] table. You can build a condition that checks the values of fields on this table; in this case, the State field. When [State] [is not] [On Hold], the UI policy applies the associated UI policy rules. When you select the Reverse if false option, a field made invisible when the state field is not On Hold is made visible when the state is On Hold.

An example screen UI policy form.

What to do next

Create UI policy rules in the related list. The screen UI policy applies these rules when the data on a screen matches the policy conditions. For details on creating these rules, see Create a UI policy rule.

Create a UI policy rule

Create UI policy rules to control whether the fields that your users see are visible or mandatory with the ServiceNow Agent mobile app.

Before you begin

Role required: ui_policy_admin or admin

Procedure

  1. Navigate to System Applications > Studio.
  2. In the Select Application pop-up window, select your mobile application.
  3. In the Application Explorer pane, point to Mobile Development > UI Policies and click the pop-out icon(pop-out icon.) that appears.
  4. Select the UI policy that you want to create rules for.
  5. In the UI Policy Rules related list, click New.
  6. On the form, fill in the fields.
    Table 2. UI Policy Rule form
    Field Description
    UI policy Screen UI policy that this rule is associated with. The field is automatically populated when you create rules from the UI policy rules related list on a screen UI policy form.
    Field name Name of the field to apply the rule to.
    Visible Options that change the visibility of a field on a screen. If the field is not available on the screen, you cannot configure a rule to make it appear.
    • Leave Alone: Rule that has no effect on the visibility of this field.
    • True: Rule that makes this field visible.
    • False: Rule that hides this field on the screen.
    Mandatory Options that change whether the field is mandatory.
    • Leave Alone: Rule that has no effect on this field.
    • True: Rule that makes this field mandatory.
    • False: Rule that makes this field non-mandatory.

Example: Use a UI policy rule to hide a field

This example shows how you can control the visibility of the On hold reason field. On hold reason is selected in the Field name field, and the Visible field is set to False. If the screen UI policy conditions are met, the On hold reason field is hidden on the screen.

UI policy rule example
Feedback