[单选题]在窗体上有一个命令按钮Command1,通用过程fun和命令按钮的事件过程如下:Private Function fun(ByVal m As Integer)Ifm Mod2=0 Thenfun=2E.lsefun=1E.nd IfE.nd FunctionPrivate Sub Command1_Click()D.im i As Integer,s As Integers=0F.or i=1 To 5s=s+fun(i)NextPrintsE.nd Sub程序运行后,单击命令按钮,则窗体上输
[单选题]在窗体上有一个命令按钮Command1,通用过程fun和命令按钮的事件过程如下: Private Function fun(ByVal m As Integer) If m Mod 2 = 0 Then fun=2 Else fun=1 End If End Function Private Sub Command1_Cliek() Dim i As Integer, s As Integer s=0 For i=1 To 5 s=s+fun(i) Next Print s End Sub 程序
[单选题]在窗体上画一个名称为Commandl的命令按钮,然后编写如下通用过程和命令按钮的事件过程: Private Function fun(By Val m As Integer) If m Mod 2=0 Then fun=2 Else fun=1 End If End Function Private Sub Commandl_Click() Dim i As Integer,s As Integer s=0 For i=1 To 5 s=s+fun(i) Next Print s End Sub
[单选题]在窗体上画一个名称为Commandl的命令按钮。单击命令按钮时执行如下事件过程:Private Sub Commandl_Click()a$=”software and hardware”b$=Right(a$,8)c$=Mid(a$,1,8)MsgBox a$,bs,cS,1E.nd sub则在弹出的信息框标题栏中显示的标题是( )。A.software and hardwareB.hardwareC.softwareD.1
[单选题]( 33 )在窗体上有一个命令按钮 Commandl ,编写事件代码如下:Private Sub Command1_Click()D.im x As Integer, y As Integerx = 12: y = 32C.all Proc(x, y)D.ebug.Print x; yE.nd SubPublic Sub Proc(n As Integer, ByVal m As Integer)n = n Mod 10m = m Mod 10E.nd Sub打开窗体运行后,单击命令按钮,立即窗
[单选题]34 )在窗体上有一个命令按钮 Commandl ,编写事件代码如下:Private Sub Commandl_Click()D.im d1 As DateD.im d2 As Datedl = #12/25/2009#d2 = #1/5/2010#MsgBox DateDiff( ” ww ” , d1, d2)E.nd Sub打开窗体运行后,单击命令按钮,消息框中输出的结果是A. ) 1B. ) 2C. ) 10D. ) 11
[单选题]( 32 )在窗体上有一个命令按钮 Commandl ,编写事件代码如下:Private Sub Commandl_Click()D.im y As Integery = 0D. oy = InputBox (" y= ")If (y Mod 10) + Int(y / 10) = 10 Then Debug.Print y ;Loop Until y = 0E.nd Sub打开窗体运行后,单击命令按钮,依次输入 10 、 37 、 50 、 55 、 64 、 20 、 28 、 19 、
[试题]( 10 )在窗体上有一个命令按钮 Commandl ,编写事件代码如下:Private Sub Command1_Click()D.im a(10), p(3) As Integerk = 5F.or i = 1 To 10a(i) = i * iNext iF.or i = 1 To 3p(i) = a(i * i)Next iF.or i = 1 To 3k = k + p(i) *2Next iMsgBox kE.nd Sub打开窗体运行后,单击命令按钮,消息框中输出的结果是 ( 10 )
[单选题]在窗体上有一个命令按钮Commandl,编写事件代码如下:Private SuB cormmandl_Click()D.im y As Integery=0D.oy=Input Box(“y=”)IF(y Mod 10)+Int(y/10)=10 Then DeBug.print y;Loop Until y=0E.nd SuB打开窗体运行后,单击命令按钮,依次输入10、37、50、55、64、20、28、19、-19、0,立即窗口上输出的结果是A.37 55 64 28 19 19B.10 5
[单选题]在窗体上有一个命令按钮Commandl,编写事件代码如下:Private SuB commandl_Click()D.im d1 As DateD.im d2 As Dated1=#12/25/2009#d2=#1/5/2010#MsgBox DateDiFF(“WW”,d1,d2)E.nd SuB打开窗体运行后,单击命令按钮,消息框中输出的结果是A.1B.2C.10D.11