Skip to main content

Set Window State

Description

Maximize or Minimize or Restore the state of the specified window.

note

This activity requires an active display and an unlocked user session to simulate interactions with UI components successfully. For more detailed information, please refer to the relevant section in the Desktop Automation Notes.

Properties

Input

  • Window Title – Holds the title of the window identified through Window Selector. You can also type in the title to identify the window for automation.

  • Window Instance - Holds the window instance identified through Window Selector. You can also type in the window instance for automation.

  • Window State - Specify the window state to be set from the dropdown

StateDescription
MaximizeMaximizes the window to fit the screen
MinimizeMinimizes the window to the taskbar
RestoreRestores the window to its original state

Misc

  • DisplayName – The display name of the activity.

  • Private – If selected, the variables and argument values will no longer be logged at the Verbose level.

Optional

  • Timeout – Specifies the maximum duration the activity will wait for a response to perform the requested operation. A timeout error occurs if no response is received within the specified time. The default timeout is 30 seconds.
  • Continue On Error – It Specifies whether the automation should continue even when the activity throws an error. If True, the activity continues without throwing any exceptions. If False, the activity throws an exception. The default value is False.
note

If this activity is inside the Try-Catch block, and the value of this property is True, no error would be caught.

Example

Download Example (C#)