vb里我要单击窗体时产生点,但是松开鼠标时这个点就消失要怎么弄,我是要在form_click里编这
vb里我要单击窗体时产生点,但是松开鼠标时这个点就消失要怎么弄,我是要在form_click里编这个...
vb里我要单击窗体时产生点,但是松开鼠标时这个点就消失要怎么弄,我是要在form_click里编这个
展开
2014-12-25
展开全部
代码如下:
Dim ax, ay As Integer
Private Sub Form_Click()
Me.PSet (ax, ay), vbRed
End Sub
Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
ax = X
ay = Y
End Sub
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Me.PSet (ax, ay), Me.BackColor
End Sub
Dim ax, ay As Integer
Private Sub Form_Click()
Me.PSet (ax, ay), vbRed
End Sub
Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
ax = X
ay = Y
End Sub
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Me.PSet (ax, ay), Me.BackColor
End Sub
更多追问追答
追问
额,忘了说了,就是必须要在鼠标点的那个地方画
追答
是啊,上面就是在你鼠标点的位置画的点啊
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询