Function ControlMove

  • Moves and resizes a control in a window.

    Parameters

    • windowTitle: string

      The title of the window to access.

    • windowText: string

      Optional text found in the window.

    • controlId: string

      The ID of the control to move or resize.

    • x: number

      The new X coordinate of the control.

    • y: number

      The new Y coordinate of the control.

    • width: number = -1

      The new width of the control. Default is -1 (no change).

    • height: number = -1

      The new height of the control. Default is -1 (no change).

    Returns number

    1 if successful, 0 otherwise.

    import { ControlMove } from '@ahmic/autoit-js';

    ControlMove('Untitled - Notepad', '', 'Edit1', 100, 100, 200, 50);