检索窗口的客户区坐标
#Include <WinAPI.au3>
_WinAPI_GetClientRect($hWnd)
$hWnd | 窗口句柄 |
成功: | 返回接收客户端坐标的 $tagRECT 结构 |
失败: | 设置 @error |
在MSDN中搜索
#include <WinAPI.au3>
_Main()
Func _Main()
Local $hwnd, $tRect
$hwnd = GUICreate("test")
$tRect = _WinAPI_GetClientRect($hwnd)
MsgBox(4096, "Rect", _
"Left..: " & DllStructGetData($tRect, "Left") & @LF & _
"Right.: " & DllStructGetData($tRect, "Right") & @LF & _
"Top...: " & DllStructGetData($tRect, "Top") & @LF & _
"Bottom: " & DllStructGetData($tRect, "Bottom"))
EndFunc ;==>_Main