程:
Private Sub Command1_Click( )
D.im i As Integer, n As Integer
F.or i=0 To 50
i=i+3
n=n+1
If i>10 Then Exit For
Next
Text1.Text=Str(n)
E.nd Sub
程序运行后,单击命令按钮,在文本框中显示的值是( )。
A.)2
B.)3
C.)4
D.)5
[单选题]在窗体上画一个名称为Command1 的命令按钮和一个名称为Text1的文本框,然后编写如下程序: Private Sub Command1_Click( ) Dim x,y,z As Integer x=5 y=7 z=0 Texttext = " " Call P1 (x,y,z) TextText = Str(z) End Sub Sub P1(ByVal a As Integer,ByVal b As Integer,c As Integer) c=a+b End Sub 程序运行后
[单选题]在窗体上画一个名称为Text1的文本框,一个名称为Command1的命令按钮,然后编写如下事件过程和通用过程:Private Sub Command1_Click()n = Val(Text1.Text) If n/2 = n/2 Then f = f1(n)Else f = f2(n)End IfPrint f; nE.nd SubPublic Function f1(ByRef x)x=x*xf1=x+xE.nd FunctionPublic Function f2(
[单选题]在窗体上画一个名称为Text1的文本框,一个名称为Command1的命令按钮,然后编写如下事件过程和通用过程: Private Sub Command1_Click() n = Val(Text1.Text) If n/2 = n/2 Then f = f1(n) Else f = f2(n) End If Print f; n End Sub Public Function f1(ByRef x) x=x*x f1=x+x End Function Public Function f2(ByV
[单选题]在窗体上画一个名称为Command1的命令按钮和一个名称为Text1的文本框,在文本框中输入以下字符串:Microsoft Visual Basic Programming然后编写如下事件过程:Private Sub Command1_Click()Open "d:/temp/outf.txt" For Output As #1F.or i = 1 To Len(Text1.Text) c = Mid(Text1.Text, i, 1) If c >= "A" And c
[单选题]在窗体上画一个名称为Text1的文本框和一个名称为Command1的命令按钮,然后编写如下事件过程:Private Sub Command1_Click()D.im array1(10, 10) As IntegerD.im i As Integer, j As IntegerF.or i = 1 To 3F.or j = 2 To 4array1(i, j) = i + jNext jNext iText1.Text = array1(2, 3) + array1(3, 4)E.nd Sub程
[单选题]在窗体上画一个名称为Command1的命令按钮和一个名称为Text1的文本框,然后编写如下事件过程:Private Sub Command1_Click()n = Val(Text1.Text)F.or i = 2 To nF.or j = 2 To sqr(i)If i Mod j = 0 Then Exit ForNext jIf j > Sqr(i) Then Print iNext iE.nd Sub该事件过程的功能是( )。A.输出n以内的奇数B.输出n以内的偶数C.输出n以内的
[单选题]在窗体上画一个名称为Text1的文本框和一个名称为Command1的命令按钮,然后编写如下事件过程:Option Base 1Private Sub Command1_Click( )D.im s As IntegerD.im aa(3, 2) As IntegerF.or i = 1 To 3F.or j = 1 To 2aa(i, j) = i + jNext jNext is = aa(1, 2) + aa(2, 1)Print sE.nd Sub程序运行后,单击命令按钮,窗体上显示的值是
[单选题]在窗体上画一个名称为Command1的命令按钮和一个名称为Text1的文本框,然后编写如下事件过程:Private Sub Command1_Click() n = Val (Text1.Text) For i = 2 To n For j = 2 To Sqr(i) If i Mod j = 0 Then Exit For Next j If j > Sqr (i) Then Print i Next iEnd Sub 该事件过程的功能是。A.输出n以内的奇数B.输出n以内的偶数C.输出
[单选题]在窗体上画一个名称为Text1的文本框和一个名称为Command1的命令按钮,然后编写如下事件过程: Private Sub Commandl_Click() Dimarrayl(10,10)As Integer Dimi As Integer,j As Integer Fori=1 To 3 Forj=2 To 4 arrayl(i,j)=i+j Nextj Nexti Text1.Text=axvayA.15B.14C.13D.12
[单选题]在窗体上画一个名称为Command1的命令按钮和一个名称为Text1的文本框,然后输写如下程序:Private Sub Command1_Click()D.im x,y,z As Integerx=5y=7z=0Text1.Text=""C.all Fun1(x,y,z)Text1.Text=Str(z)E.nd SubSub Fun1(ByVal a As Integer,ByVal b As Integer,c As Integer)c=a+bE.nd Sub程序运行后,如果单击命令按钮