The Window Object - Script2CMD Programming Interface

Document Path: Home Page / Programming / Script2CMD / Interfaces / Window Object  
Properties ActiveWindow ClassName ClientHeight ClientWidth DesktopWindow Enable ExtStyles FocusWindow ForegroundWindow Handle Height ProcessID Styles ThreadID Visible Width WindowText X Y
Methods CenterWindow ClickToActivate IsWindow ModifyStyle ModifyStyleEx MoveBy PostMessage RedrawWindow SendMessage SendMessageCallback SendMessageTimeout SetFocus SetForegroundWindow SetLayeredWindowAttributes SetWindowPos SetWindowRgn ShowWindow SwitchToThisWindow UpdateWindow
Properties

ActiveWindow

Value ULONG
Access Get
Notes

ClassName

Value BSTR
Access Get
Notes

ClientHeight

Value ULONG
Access Get, Put
Notes

ClientWidth

Value ULONG
Access Get, Put
Notes

DesktopWindow

Value ULONG
Access Get
Notes

Enable

Value BOOL
Access Get, Put
Notes

ExtStyles

Value ULONG
Access Get, Put
Notes

FocusWindow

Value ULONG
Access Get
Notes

ForegroundWindow

Value ULONG
Access Get
Notes

Handle

Value ULONG
Access Get, Put
Notes

Height

Value ULONG
Access Get, Put
Notes

ProcessID

Value ULONG
Access Get
Notes

Styles

Value ULONG
Access Get, Put
Notes

ThreadID

Value ULONG
Access Get
Notes

Visible

Value BOOL
Access Get, Put
Notes

Width

Value ULONG
Access Get, Put
Notes

WindowText

Value BSTR
Access Get, Put
Notes

X

Value long
Access Get, Put
Notes

Y

Value long
Access Get, Put
Notes
Methods

CenterWindow

Return Value
Arguments:
  • Object windowObj (Optional, default(0))
Notes

ClickToActivate

Return Value VARIANT_BOOL
Notes

IsWindow

Return Value BOOL
Notes

ModifyStyle

Return Value
Arguments:
  • ULONG stylesToRemove
  • ULONG stylesToAdd
Notes

ModifyStyleEx

Return Value
Arguments:
  • ULONG exStylesToRemove
  • ULONG exStylesToAdd
Notes

MoveBy

Return Value
Arguments:
  • long x
  • long y
Notes

PostMessage

Return Value VARIANT_BOOL
Arguments:
  • ULONG msg
  • ULONG wParam
  • ULONG lparam
Notes

RedrawWindow

Return Value
Notes

SendMessage

Return Value long
Arguments:
  • ULONG msg
  • ULONG wParam
  • ULONG lparam
Notes

SendMessageCallback

Return Value VARIANT_BOOL
Arguments:
  • ULONG msg
  • ULONG wparam
  • ULONG lparam
  • Object callbackFunc
Notes

SendMessageTimeout

Return Value VARIANT
Arguments:
  • ULONG msg
  • ULONG wparam
  • ULONG lparam
  • ULONG flags
  • ULONG timeout
Notes

SetFocus

Return Value
Notes

SetForegroundWindow

Return Value
Notes

SetLayeredWindowAttributes

Return Value VARIANT_BOOL
Arguments:
  • unsigned char red
  • unsigned char green
  • unsigned char blue
  • unsigned char alpha
  • VARIANT_BOOL useColorKey
  • VARIANT_BOOL useAlpha
Notes

SetWindowPos

Return Value
Arguments:
  • ULONG hWndInsertAfter
  • long x
  • long y
  • long cx
  • long cy
  • ULONG flags
Notes

SetWindowRgn

Return Value
Arguments:
  • ULONG hRgn
Notes

ShowWindow

Return Value
Arguments:
  • ULONG cmdShow
Notes

SwitchToThisWindow

Return Value
Arguments:
  • BOOL fAltTab (Optional, default(0))
Notes

UpdateWindow

Return Value
Notes