呵呵..给你个全部的例子你就知道了.. 使用了一个timer Private Declare Function GetCursorPos Lib "user32" (lpPoint As POINTAPI) As Long Private Type POINTAPI '主要是漏了这个 x As Long y As Long End Type Dim z As POINTAPI Private Sub Form_Load() Timer1.Interval = 100 End Sub Private Sub Timer1_Timer() GetCursorPos z Cls Print z.x Print z.y End Sub
vb用户定义类型未定义: Public Declare Function GetCursorPos Lib "user32" (lpPoint As POINTAPI) As Long ;
最新推荐文章于 2021-09-02 22:40:34 发布