ExpandCollapse

This action allows you to expand or collapse the menu of the selected application
on the desktop.

Technical Reference

 

 

Input

Action: This parameter allows you to trigger the action that needs to be performed and offers two options:

 

Expand: This option indicates expanding the 'Menu' to view the available options.

Collapse: This option indicates collapsing the 'Menu' to hide the options.

By default, it is set to the 'Expand' option.

DelayAfter: It assists the user to add a delay before initiating subsequent activities.

The delay duration here is in milliseconds. By default, it is set to "300" milliseconds.
When the option is left blank, the delay will not be considered.

DelayBefore: It assists the user in adding a delay before starting the execution of the activities.

The delay duration here is in milliseconds. By default, it is set to "300" milliseconds.
When the option is left blank, the delay will not be considered.

ExecuteBy: Gets auto filled once the "Active Application" is selected. This contains the set of attributes for the specific spied element.

WaitTime:  It helps the user to add a delay to start the execution of the further activity. The format of the delay here is milliseconds. By default, it will be set to 10000. When the option is left blank, no delay is considered.

 

Misc

DisplayName: Displays the name of the activity. The activity name can be customized, which aids in troubleshooting.

SkipOnError: Specify the "Boolean" value as "True" or "False."

 

True: Continue executing the workflow regardless of any errors thrown.

False: Halt the workflow if it encounters any errors.

None: If the option is left blank, the activity will, by default, behave as if "False" were chosen.

Version: It indicates the version of the feature being used.

Output

Result: It provides the ability to view the execution status of the activity. It returns values in "Boolean."

 

True: Indicates that the activity has been executed successfully without any errors.

False: Indicates that the activity has been unsuccessful due to an unexpected error being thrown.

Represents mandatory fields to execute the workflow

Here’s an example of how the “ExpandCollapse” Menu works –

In the following example, I will demonstrate the automation of the 'Notepad' application,
where I expand the 'Help Menu' and click on the 'View Help' button. Please note that
I have already launched the 'Notepad' application.

1.       Drag and drop the "ExpandCollapse" activity into the workflow.

2.       This activity allows you to expand or collapse a menu. In this example, I will
expand the "Help" menu in Notepad.

3.       Double-click the activity to choose the "Select element" option for detecting the
"Menu" in Notepad.

 

 

a.       Navigate to the "Notepad" application and select the "Help" menu to identify the
element for automation.

b.       Once you've chosen the elements, they will appear in the "Spy" window, along
with an image.

i.      If you need to add or remove attributes, you can do so in the "Attributes Editor."
In this case, no changes are required in the editor.

ii.      Click the "Save" button to store the application's element in the activity window.

c.       Navigating to the “Action” on the properties of the activity to select the action to
be performed.

i.      In this case, I am going to choose the “Action” as “Expand” option.

4.       Now, add the "Click" activity after the "ExpandCollapse" activity.

a.       Use this activity to click on the "View Help" option when the "Help" menu
expands in Notepad.

b.       Double-click on the activity and select the element where you want to perform
the click, then proceed to the next step.

c.       Once you have selected the "Element," its attributes will be stored in the "Spy"
window, along with an image of the element.

i.      If you need to add or remove any attributes, you can edit the "Attributes Editor."
In this case, we are not making any changes in the “Editor.”

ii.      Clicking the "Save" button will store the elements in the activity window.