Toggle Object

How to use the Toggle object on the screen

Updated over a week ago

A toggle allows the user to set a value to Yes (True) or No (False).


Accessing value of Toggle object

The Toggle object object will hold a value of either

  • True (Yes)

  • False (No)

This value can be altered by using the Update Controls on Screen action.

When an action requires you to 'Assign a value', you can use the value set in the toggle object.

Example:

The below image shows an Assign Value to Action Result action. It will assign the value stored in the toggle object called "Toggle".


Toggle Object Properties

When you select the toggle object, you will be able to set its settings, style, and events.

Settings

  • Caption: The name for your object. Used for display on screen and to uniquely identify the object within actions.

  • Hide Caption: If you’re just labeling your control for your own information but don’t want the text to show in the live screen, check this box.

  • Load State: The initial state when the screen loads.

  • Initially Set to On: Set the toggle to "on" by default.

  • Toggle Text: Text to show on the toggle. Options include:

    • Blank (no text)

    • Yes / No

    • On / Off

  • Width: How wide should your control be in relation to the screen? For more information, check out Styling Basics.

Style

  • Caption Color: Choose the caption color.

  • Caption Size: Choose the caption size.

  • Caption Text Align: Specify the alignment of your caption.

  • Caption Align: Change the alignment of your caption.

  • Toggle Background Color: Set the background color of this control from the preset Method palette.

Actions / Events

  • Change - Event is triggered when a user toggles the object.

Did this answer your question?