单击命令按钮时,下列程序的执行结果是 Private Sub Command1_Click( ) Dim a As Integer,b As Integer,c As Integer a=3 b=4 C=5 Print SecProc(c,b,A)End Sub Function Fir Proc(x As Integer,y As Integer,z As Integer) Fir Proc=2*x+y+3*z End Function Function SecProc(x As Integer,y As Integer,z As Integer) SecProc=FirProc(z,x,y)+x End Function
A.20
B.22
C.28
D.30
第1题:
单击命令按钮时,下列程序段的执行结果为( )。
A.8
B.6
C.4
D.2
第2题:
单击命令按钮时,下列程序的执行结果是
Private Sub Command1_Click()
BT 4
End Sub
Private Sub BT(x As Integer)
x=x*2 + 1
If x < 6 Then
Call BT(x)
End If
x=x 2
Print x;
End Sub
A.15
B.16
C.17
D.18
第3题:
单击命令按钮时,下列程序的执行结果是
Private Sub Command1_Click()
BT 4
End Sub
Private Sub BT(x As Integer)
x=x * 2 + 1
If x < 6 Then
Call BT(x)
End If
x=x * 2
Print x;
End Sub( )。
A.15
B.16
C.17
D.18
第4题:
单击命令按钮时,下列程序的执行结果是 Private Sub Commandl_Click( ) BT 4 End Sub PriVate Sub BT(x As Integer) X=X * 2 + 1 If x <6 Then Call BT(x) End If X=x * 2 Print x; End Sub
A.15
B.16
C.17
D.18
第5题:
若看到程序中确以下事件过程,则可以肯定的是,当程序运行时( )。
Private Sub Click—MouseDown(Button As Integer,Shift As Integer,X As Single,Y
As Single)
Print"VB Program"
End Sub
A.用鼠标左键单击名称为“Command1”的命令按钮时,执行此过程
B.用鼠标左键单击名称为“MouseDown”的命令按钮时,执行此过程
C.用鼠标右键单击名称为“MouseDown”的命令按钮时,执行此过程
D.用鼠标左键或右键单击名称为“Click”的命令按钮时,执行此过程
第6题:
设有命令按钮Commandl的单击事件过程,代码如下:运行程序,单击命令按钮,消息框输出结果是( )。
A. 7
B. 8
C. 15
D. 22
第7题:
若看到程序中确以下事件过程,则可以肯定的是,当程序运行时( )。 Private Sub Click—MouseDown(Button As Integer,Shift As Integer,X As Single,Y As Single) Print"VB Program" End Sub
A.用鼠标左键单击名称为“Command1”的命令按钮时,执行此过程
B.用鼠标左键单击名称为“MouseDown”的命令按钮时,执行此过程
C.用鼠标右键单击名称为“MouseDown”的命令按钮时,执行此过程
D.用鼠标左键或右键单击名称为“Click”的命令按钮时,执行此过程
第8题:
在窗体上画一个命令按钮,然后编写如下程序:
Dim x As Integer
Sub inc(a As Integer)
x=x+a
End Sub
Private Sub Command1_Click()
inc 2
inc 3
inc 4
Msgbox x;
End Sub
程序执行后,单击Command1命令按钮,消息框显示结果是【 】。
第9题:
单击命令按钮时,下列程序的执行结果是 Private Sub Book(x As Integer) x=x * 2 + l If x<6 Then Call Book(x) End If X=X * 2 + 1 Print x; End Sub Private Sub Command2_Click() Book2 End Sub
A.23 47
B.10 36
C.22 44
D.24 50
第10题:
在窗体上画一个名为Command1的命令按钮,编写如下程序:
程序运行后,单击命令按钮,输出的结果是_________。