Get Screen Dimensions
AutomatR.Windows.Activities.GetScreenDimensions
The "Get Screen Dimensions" activity in AutomatR for Windows UI Automation retrieves the width and height of the primary screen. This information is valuable when designing or interacting with elements on the screen to ensure accurate positioning and scaling in automation workflows.
Properties
Name | Description |
---|---|
Misc | |
Display Name | Provides a customizable name for the activity displayed in the workflow. String variables containing the desired display name. |
Output | |
Width | Outputs the width of the primary screen. Double variables to store the screen width. |
Height | Outputs the height of the primary screen. Double variables to store the screen height. |
How to use:
- Drag and drop the "Get Screen Dimensions" activity onto the workflow.
- Execute the workflow to retrieve the width and height of the primary screen.
- Use the output variables (Width and Height) in subsequent activities for accurate positioning and scaling.
Example: Consider an example where the "Get Screen Dimensions" activity is used to obtain and store the screen dimensions:
Get Screen Dimensions:
Display Name: "Retrieve Screen Dimensions"
Width: screenWidth
Height: screenHeight
In this example, the activity retrieves the width and height of the primary screen, and the values are stored in the variables "screenWidth" and "screenHeight" for further use in the workflow.