how do i detect if a secondary monitor is on? i'd like to move a window to the secondary monitor only if its on and to let it remain on the primary monitor if its off.
Alright then, UIAutomation is another way to achieve it under win 10
#include <Constants.au3>
#include <Array.au3>
#include "Includes\CUIAutomation2.au3"
Opt("MustDeclareVars", 1)
Run("control.exe desk.cpl,Settings,@Settings")
GetMonitor()
Func GetMonitor()
Local $hWnd = WinWait("[CLASS:ApplicationFrameWindow]")
ConsoleWrite($hWnd & @CRLF)
Local $oUIAutomation = ObjCreateInterface($sCLSID_CUIAuto