网友您好, 请在下方输入框内输入要搜索的题目:
题目内容
(请给出正确答案)
假定在窗体中的通用声明段已经定义有如下的子过程:
Sub f(x As Single,y As Single)
t=x
x=y
y=x
End Sub
在窗体上添加一个命令按钮(名为Command1),然后编写如下事件过程:
PrivateSubCommand1_Click()
a=10
b=20
f(a,B)
MsgBox a&b
End Sub
打开窗体运行后,单击命令按钮,消息框输出的值分别为( )。
A.20和10
B.10和20
C.10和10
D.20和20
参考答案
更多 “ 假定在窗体中的通用声明段已经定义有如下的子过程:Sub f(x As Single,y As Single)t=xx=yy=xEnd Sub在窗体上添加一个命令按钮(名为Command1),然后编写如下事件过程:PrivateSubCommand1_Click()a=10b=20f(a,B)MsgBox abEnd Sub打开窗体运行后,单击命令按钮,消息框输出的值分别为( )。A.20和10B.10和20C.10和10D.20和20 ” 相关考题
考题
假定有如下的Sub过程:Sub sfun(x As Single,y As Single)t=xx=t/yy=t Mod yEnd Sub在窗体上添加一个命令按钮(名为Command1),然后编写如下事件过程:Private Sub Command1_Click()Dim a as singleDim b as singlea=5b=4sfun a,bMsgBox a chr(10)+chr(13) bEnd Sub打开窗体运行后,单击命令按钮,消息框的两行输出内容分别为A.1和1B.1.25和1C.1.25和4D.5和4
考题
(12)有下列Sub过程: Sub Sub(x As Single,y As Single) t=x x=t/y y=t Mody End Sub 在窗体上的命令按钮Commandl中,编写下列事件过程,执行该事件过程调用Sun过程,结果是( )。 Private Sub Commandl_Click() Dim a As Single Dim b As Single a=5 b=4 Sun a,b Print a;b End Sub A.1.25 1 B.5 4 C.4 5 D.1 1.25
考题
有如下SUB过程:Sub s(x As Single,y As Single)t=xx=t / yy=t Mod yEnd Sub在窗体上添加一个命令按钮,然后编写如下事件过程:Private Sub Form_Click()Dim a As SingleDim b As Singlea=5b=4s a,bPrint a,bEnd Sub则程序运行后,单击命令按钮,输出的结果为【 】 。
考题
假定有如下的Sub过程: Sub sfun(x As Single,y As Single) t=x x=t/y y=t Mod y End Sub 在窗体上添加一个命令按钮(名为Command1),然后编写如下事件过程: Private Sub Command1 Click() Dim a as single Dim b as single a=5 b=4 sfun a,b MsgBox a chr(10)+chr(13)b End Sub 打开窗体运行后,单击命令按钮,消息框的两行输出内容分别为( )。A.1n1B.1.25和1C.1.25和4D.5和4
考题
下面程序是由鼠标事件在窗体上画图,如果按下鼠标可以画图,双击窗体则可以清除所画图形。补充完整下面的程序。首先在窗体层定义如下变量:Dim PaintStart As Boolean编写如下事件过程:Private Sub Form_Load()DrawWidth=2ForeColor=vbGreenEnd SubPrivate Sub Form_MouseDown(Button As Integer,Shift As Integer,X AS Single,Y AS Single)PaintStart=TrueEnd SubPrivate Sub Form_MouseMove(Button As Integer,Shift As Integer,X As Single,Y As Single)If PaintStart ThenPSet(X,Y)End IfEnd SubPrivate Sub Form_MouseUp(Button As Integer,Shift As Integer,X As Single,Y As Single)End SubPrivate Sub Form_DblClick()ClsEnd Sub
考题
有如下程序: Private Sub Command1_Click() Dim a As Single Dim b As Single a=5:b=4 Call Sub1(a,b) End Sub Sub Sub1(x As Single,y As Single) t=X X=t\Y Y=t Mod y End Sub 在调用运行上述程序后,a和b的值分别为A.0 0B. 1 1C.2 2D.1 2
考题
编写如下通用过程: Sub Proc(x As Single,y As Single) t=x x=t/y y=t Mod y End Sub 在窗体上画一个命令按钮,然后编写如下事件过程: Private Sub Commandl Click() Dim a As Single Dim b As Single a=5 b=4 Proc a,b Print a,b End Sub 程序运行后,如果单击命令按钮,则输出结果为A.5 4B.1.25 1C.4 5D.1.25 5
考题
假定有如下的Sub过程: Sub Func(x As Single, y As Single) t=x x=t/y y=t Mod y End Sub 在窗体上画一个命令按钮,然后编写如下事件过程: Private Sub Command1_Click() Dim a As Single Dim b As Single a=6 b=5 Func(a, B) Print a, b End Sub 程序运行后,单击命令按钮,输出结果为 ______。A.6 5B.1 1C.1.2 5D.1.2 1
考题
假定有如下的Sub过程: Sub S(x As Single,y As Single) t=x x=t/y y=t Mod y End Sub 在窗体上画一个命令按钮,然后编写如下事件过程: Private Sub Command1_Click() Dim a As Single Dim b As Single a=5 b=2 S a,b print a,b End Sub 程序运行后,单击命令按钮,输出结果是( )。A.5 2B.1 1C.1.25 4D.2.5 1
考题
若有如下Sub过程:Sub sfun(x As Single,y As Single)t=Xx=t/yy=t Mod YEnd Sub在窗体中添加一个命令按钮Command33,对应的事件过程如下:Private Sub Command33_Click()Dim a As SingleDim b As Singlea=5: b=4sfun a,bMsgBox a&chr(10)+chr(13)bEnd Sub打开窗体运行后,单击命令按钮,消息框中有两行输出,内容分别为A.1和1B.1.25和1C.1.25和4D.5和4
考题
假定有如下的Sub过程: Sub sfun(x As Single,y As SinglE)t=x x=t/y y=t Mod y End Sub 在窗体上添加一个命令按钮(名为Command1),然后编写如下事件过程: Private Sub Command1_Click( ) Dim a as single Dim b as single a=5 b=4 sfun a,b MsgBox a char(10A.1和1B. 1.25和1C. 1.25和4D. 5和4
考题
假定有如下的Sub过程:Sub Sub1(x As Single,y As single)t=xx=t/yy=t Mod yEnd Sub在窗体上画一个命令按钮,然后编写如下事件过程:Private Sub Command1_click()Dim a As SingleDim b As Singlea=5b=4Sub1 a,bPrint a;bEnd Sub程序运行后,单击命令按钮,输出结果为A.B.C.D.
考题
假定有如下的Sub过程:Sub Sub1(x As Single, y As single)t=xx=t / yy=t Mod yEnd Sub在窗体上画一个命令按钮,然后编写如下事件过程:Private Sub Command1_Click()Dim a As SingleDim b As Singlea=5b=4Sub1 a,bPrint a;bEnd Sub程序运行后,单击命令按钮,输出结果为A.54B.] 1]]1C.] 1.2]]5.4D.] 1.25]]1
考题
有如下程序。 Private Sub Commandl_Click() Dim a As Single Dim b As Single a=5:b=4 Call Sub1 ( a,B)End Sub Sub Subl(x As Single, y As Single) t=x x=t\y y = t Mod y End Sub 在调用运行上述程序后,a和b的值分别为A.0 0B.1 1C.2D.1 2
考题
假定有如下的Sub过程:Sub Sub1 (x As Single, y As Single) t=x x = t/y y = t Mod yEnd Sub 在窗体上画一个命令按钮,然后编写如下事件过程:Private Sub Command1_ Click() Dim a As Single Dim b As Single a = 5 b = 4 Sub1 a, b Print a; b End Sub 程序运行后,单击命令按钮,输出结果为______。A.5 4B.1 1C.1.2 5.4D.1.25 1
考题
假定有如下的Sub过程: Sub sfun(X As Single,Y As Single)t=Xx=t/yY=tModYEnd Sub在窗体上添加一个命令按钮(名为Commandl),然后编写如下事件过程: Private Sub Commandl_Click() Dim aAs singleDimbAs singlea=5b=4sfun a,bMsgBox a&;chr(10)+chr(131&;bEndSub打开窗体运行后,单击命令按钮,消息框的两行输出内容分别为( )。A.1和1B.1.25和1C.1.25和4D.5和4
考题
假定在窗体中的通用声明段已经定义有如下的子过程: Sub f(x As Single,Y As Single)t=xx=yy=xEndSub在窗体上添加一个命令按钮(名为Commandl),然后编写如下事件过程。 Private Sub CommandLClick( ) a=10b=20f(a,B. MsgBox a&;bEndSub打开窗体运行后,单击命令按钮,消息框输出的值分别为( )。A.20和10B.10和20C.10和10D.20和20
考题
假定在窗体中的通用声明段已经定义有如下的子过程: Sub fix As Single,Y As Single)t=xx=yy=xEnd Sub在窗体上添加一个命令按钮(名为Commandl),然后编写如下事件过程: Private Sub Commandl_Click( ) a=10b=20f(a,B. MsgBox a&bEnd Sub打开窗体运行后,单击命令按钮,消息框输出的值分别为( )。A.20和10B.10和20C.10和10D.20和20
考题
假定有如下的Sub过程: Sub sfun(X As Single,y As Single)t=XX=t/yY=tModYEndSub在窗体上添加一个命令按钮(名为Commandl),然后编写如下事件过程。 Private Sub Commandl Click( ) Dim aAs singleDimbAs singlea=5b=4sfun a,bMsgBOX a&;chr(10)+chr(13)&;bEndSub打开窗体运行后,单击命令按钮,消息框的两行输出内容分别为( )。A.1和1B.1.25和1C.1.25和4D.5和4
考题
假定在窗体中的通用声明段已经定义有如下的子过程: Subf(x As Single,y As Single) t=x x=y y=x End Sub 在窗体上添加一个命令按钮(名为Commandl),然后编写如下事件过程: Pfivme Sub Commandl_Click() a=10 b=20 f(a,B) MsgBox ab End Sub 打开窗体运行后,单击命令按钮,消息框输出的值分别为( )A.20和10B.10和20C.10和10D.20和20
考题
现有如下Sub过程: Sub fun(x es single,y as single) t = x x = t/y y = t mod y End sub在窗体上添加命令按钮(cmD) ,编写如下事件过程: Private sub cmd_click( ) Dim a as single Dim b as single a = 5 b = 4 fun a, b Msgbox a chr(10) + chr(13) b End sub运行程序后,单击按钮,则在消息框中显示的内容为( )A.1和1B.1.25和1C.1.25和4D.5和4
考题
有如下程序。Private Sub Command1_Click()Dim a As SingleDim b As Singlea=5: b=4Call Sub1(a, b)End SubSub Sub1(x As Single, y As Single)t=xx=t \ yy=t Mod yEnd Sub在调用运行上述程序后,a和b的值分别为A.0 0B.1 1C.2 2D.1 2
考题
有如下程序: Private Sub Command1 Click() Dim a As Single Dim b As Single a=5:b=4 Call S(a,B)End Sub Sub S(x As Single,y As Single) t=x x=t\y y=t Mod y End Sub 在调用运行上述程序后,a和b的值分别为A.0 0B.1 1C.2 2D.1 2
考题
有如下Sub过程: Sub Sun(x As Single, y As Single) t=x x=t/y y=t Mod y End Sub 在窗体上的命令按钮Command1中,编写如下事件过程,执行该事件过程调用Sun过程,结果为( )。 Private Sub Command1_Click() Dim a As Single Dim b As Single a=5 b=4 Sun a, b Print a; b End SubA.1.25 1B.5 4C.4 5D.1 1.25
考题
有下列Sub过程:Sub Sun(x As Single,y As Single)t=xx=t/yy=t ModyEnd Sub在窗体上的命令按钮Command1中,编写下列事件过程,执行该事件过程调用Sun过程,结果是( )。Private Sub Conunandl Cliek()Dim a As SingleDim b As Singlea=5b=4Sun a,bPrint a;bEnd SubA.1.25 1B.5 4C.4 5D.1 1.25
考题
试题33若有如下Sub过程:Sub sfun(x As Single , y As Single)t=xx=t/yy=t Mod yEnd Sub在窗口中添加一个命令按钮Command33,对应的事件过程如下:Private Sub Command32_Click()Dim a As SingleDim b As Singlea = 5 : b = 4sfun( a , b )MsgBox a chr(10) + chr(13) bEnd Sub打开窗体后,单击命令按钮,消息框中有两行输出,内容分别是()A.1和1B.1.25和1C.1.25和4D.5和4
考题
单选题假定有如下的Sub过程: SubS (x As Single, y As Single) t = x x = t / y y = t Mod y End Sub 在窗体上添加一个命令按钮,然后编写如下事件过程: Private Sub Command1_Click( ) Dim a As Single Dim b As Singlea = 5: b = 4 S a, b Print a, b End Sub 程序运行时,单击命令按钮得到的结果()。A
54B
11C
1.254D
1.251
热门标签
最新试卷