如何获取窗口外的鼠标坐标
Private Declare Function GetCursorPos Lib "user32" (lpPoint As POINTAPI) As Long '声明api函数Private Type POINTAPI '声明数据类型
x As Long
y As Long
End Type
Dim z As POINTAPI '声明变量
Private Sub form_click()
GetCursorPos z '获取坐标
pos = "pos:x:" & z.x & " y:" & z.y
List1.AddItem pos
End Sub我只能获取窗口内的坐标。怎么获取窗口外的坐标?有大神帮我修改下。或者指点下!