Created
June 5, 2015 07:18
-
-
Save sl5net/d837ca8ef18fbf05e8cc to your computer and use it in GitHub Desktop.
monitors2txt.ahk
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; Example #1: | |
SysGet, MouseButtonCount, 43 | |
SysGet, VirtualScreenWidth, 78 | |
SysGet, VirtualScreenHeight, 79 | |
; Example #2: This is a working script that displays info about each monitor: | |
SysGet, MonitorCount, MonitorCount | |
SysGet, MonitorPrimary, MonitorPrimary | |
monitorTXT := "Monit!or15-06-05_07-57.txt" ; dateinamen für die ausgabe der monitor daten | |
IfExist,%monitorTXT% | |
FileDelete,%monitorTXT% | |
Sleep,100 | |
monitor_Count = Monitor Count:`t%MonitorCount%`nPrimary Monitor:`t%MonitorPrimary% | |
FileAppend,%monitor_Count%, %monitorTXT% | |
Loop, %MonitorCount% | |
{ | |
SysGet, MonitorName, MonitorName, %A_Index% | |
SysGet, Monitor, Monitor, %A_Index% | |
SysGet, MonitorWorkArea, MonitorWorkArea, %A_Index% | |
width := MonitorRight - MonitorLeft | |
monitor_t_A_Index = Monitor:`t#%A_Index%`nName:`t%MonitorName%`n%width% := width `nLeft:`t%MonitorLeft% (%MonitorWorkAreaLeft% work)`nTop:`t%MonitorTop% (%MonitorWorkAreaTop% work)`nRight:`t%MonitorRight% (%MonitorWorkAreaRight% work)`nBottom:`t%MonitorBottom% (%MonitorWorkAreaBottom% work) | |
FileAppend,%monitor_t_A_Index%, %monitorTXT% | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment