【发布时间】:2013-01-01 11:38:11
【问题描述】:
我尝试获取当前监视器状态并在http://msdn.microsoft.com/en-us/library/windows/desktop/dd144901(v=vs.85).aspx 找到GetMonitorInfo 函数,但我不知道c++ 以及如何在autohotkey 中使用它。 DllCall 行只是一个猜测,所以这是我现在写的。
MonitorStatus := 1 > 2 ; Creates a boolean variable so size of it is determined.
Sleep 1000
DllCall("GetMonitorInfo","HMONITOR",1,"LPMONITORINFO",MonitorStatus,"int")
Sleep 1000
MsgBox Monitor status is %MonitorStatus%. ; Status should be turned to 1.
Return
假设显示器有电,如何检测显示器是打开还是关闭?
【问题讨论】:
标签: c++ autohotkey c++ windows windows-8 desktop-application autohotkey