Skip to main content

Move-Window-Position

Command Description

Move the window to a new position in screen coordinates (in pixel)

Command Prototype

Window.Move(objUiElement,x,y)

Parameter Description

ParameterRequiredTypeDefaultDescription
objUiElementTruedecorator@ui""Corresponding window object; when passed as an integer, it is used as a window handle; when passed as a string, it is used as a window feature to find all matched window to operate; when passed as a UiElement object, operate the window containing it
xTruenumber0X-coordinate of the new position to move to
yTruenumber0Y-coordinate of the new position to move to

Demo

TracePrint "--------------------Move window position--------------------" 
// --------------------------------------------------------
// [Remarks] Move the window position, the Demo uses IE to open Baidu
// Input parameter 1:
// objUiElement--target element
// Input parameter 2:
// x--abscissa
// Input parameter 3:
// y--ordinate

// Command prototype: Window.Move(objUiElement,x,y)
// --------------------------------------------------------

Window.Move(@ui"window_Baidu, you will know-user configuration 1-MicrosoftEdge6",500,700)