#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=E:\百度云同步盘\P\AU3\AU3脚本代码\系统常用宏.kxf
$Form1 = GUICreate("Form1", 774, 461, 192, 124)
$Label1 = GUICtrlCreateLabel("常用系统信息宏", 184, 16, 263, 39)
GUICtrlSetFont(-1, 26, 800, 0, "楷体")
GUICtrlSetColor(-1, 0x0000FF)
$Label2 = GUICtrlCreateLabel("@CPUArch:", 40, 72, 106, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label3 = GUICtrlCreateLabel("-", 216, 72, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label4 = GUICtrlCreateLabel("@OSLang:", 40, 112, 97, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label5 = GUICtrlCreateLabel("-", 216, 112, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label6 = GUICtrlCreateLabel("@OSBuild:", 40, 152, 97, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label7 = GUICtrlCreateLabel("-", 216, 152, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label8 = GUICtrlCreateLabel("@ComputerName:", 40, 192, 162, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label9 = GUICtrlCreateLabel("-", 216, 192, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label10 = GUICtrlCreateLabel("@IPAddress1:", 40, 232, 124, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label11 = GUICtrlCreateLabel("-", 216, 232, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label12 = GUICtrlCreateLabel("@IPAddress3:", 40, 272, 124, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label13 = GUICtrlCreateLabel("-", 216, 272, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label14 = GUICtrlCreateLabel("@DesktopHeight:", 40, 312, 151, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label15 = GUICtrlCreateLabel("-", 216, 312, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label16 = GUICtrlCreateLabel("@DesktopDepth:", 40, 352, 146, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label17 = GUICtrlCreateLabel("-", 216, 352, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label18 = GUICtrlCreateLabel("@OSArch:", 400, 72, 95, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label19 = GUICtrlCreateLabel("-", 576, 72, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label20 = GUICtrlCreateLabel("@OSVersion:", 400, 112, 120, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label21 = GUICtrlCreateLabel("-", 576, 112, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label22 = GUICtrlCreateLabel("@OSServicePack:", 400, 152, 159, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label23 = GUICtrlCreateLabel("-", 576, 152, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label24 = GUICtrlCreateLabel("@UserName:", 400, 192, 118, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label25 = GUICtrlCreateLabel("-", 576, 192, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label26 = GUICtrlCreateLabel("@IPAddress2:", 400, 232, 124, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label27 = GUICtrlCreateLabel("-", 576, 232, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label28 = GUICtrlCreateLabel("@IPAddress4:", 400, 272, 124, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label29 = GUICtrlCreateLabel("-", 576, 272, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label30 = GUICtrlCreateLabel("@DesktopWidth:", 400, 312, 144, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label31 = GUICtrlCreateLabel("-", 576, 312, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Label32 = GUICtrlCreateLabel("@DesktopRefresh:", 400, 352, 161, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Label33 = GUICtrlCreateLabel("-", 576, 352, 100, 28)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0xFF0000)
$Button1 = GUICtrlCreateButton("获取系统信息", 16, 416, 99, 25)
$Button2 = GUICtrlCreateButton("关闭", 136, 416, 75, 25)
$Label34 = GUICtrlCreateLabel("2013-12-22", 240, 424, 74, 17)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
GUICtrlSetData($label3,@CPUArch)
GUICtrlSetData($label19,@OSArch)
GUICtrlSetData($label5,@OSLang)
GUICtrlSetData($label21,@OSVersion)
GUICtrlSetData($label7,@OSBuild)
GUICtrlSetData($label23,@OSServicePack)
GUICtrlSetData($label9,@ComputerName)
GUICtrlSetData($Label25,@UserName)
GUICtrlSetData($label11,@IPAddress1)
GUICtrlSetData($Label27,@IPAddress2)
GUICtrlSetData($label13,@IPAddress3)
GUICtrlSetData($Label29,@IPAddress4)
GUICtrlSetData($Label15,@DesktopHeight)
GUICtrlSetData($label31,@DesktopWidth)
GUICtrlSetData($label17,@DesktopDepth)
GUICtrlSetData($label33,@DesktopRefresh)
Case $Button2
Exit
EndSwitch
WEnd