Private Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
Cursor.Position = New Point(150, 150)
mouse_event(&H2)
Cursor.Position = New Point(250, 250)
mouse_event(&H4)
Cursor.Position = New Point(250, 250)
mouse_event(&H8)
Cursor.Position = New Point(350, 350)
mouse_event(&H10)
End Sub
上面的代码,我遇到Button1.Click
的错误,无法弄清楚原因:
Handles子句要求使用包含类型或其基本类型之一定义的
WithEvents
变量。