填空题 VB
题号 #150919

下面程序是由鼠标事件在窗体上画图,如果按下鼠标将可以画图,双击窗体可以清除所画图形。补充完整下面的程序。 
首先在窗体层定义如下变量: 
Dim PaintStart As Boolean 
编写如下事件过程: 
Private Sub Form_Load()  
 DrawWidth=2 
 ForeColor=vbGreen 
End Sub 
Private Sub Form_MouseDown(Button As Integer, Shift As Integer, _ 
         X As Single, Y As Single)  
   【13】  
End Sub 
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, _ 
         X As Single, Y As Single)  
 If PaintStart Then 
   PSet (X, Y)  
 End If 
End Sub 
Private Sub Form_MouseUp(Button As Integer, Shift As Integer, _ 
         X As Single, Y As Single)  
   【14】  
End Sub 
Private Sub Form_DblClick()  
   【15】  
End Sub  

进入在线模考

参考答案

暂无

答案解析

正确答案:  1.(PaintStart = True) 2.(PaintStart = False) 3.(Cls) 

你可能感兴趣的试题

A.有且只有1  
B.1或多于1  
C.0或1  
D.至少2
A.e3,e1,e4,e2  
B.e4,e3,e2,e1  
C.e3,e4,e1,e2  
D.任意顺序
找试题 · 找答案 · 找资料 在线模考