单项选择题
在窗体上画一个列表框和一个命令按钮,其名称分别为List1和Command1,然后编写如下事件过程。 Private Sub Form_Load() List1.AddItem "Item 1" List1.AddItem "Item 2" List1.AddItem "Item 3" End Sub Private Sub Command1_Click() List1.List(List1.Listcount)="AAAA" End Sub 程序运行后,单击命令按钮,其结果为
A.把字符串"AAAA"添加到列表框中,但位置不能确定
B.把字符串"AAAA"添加到列表框的最后(即"Item 3"的后面)
C.把列表框中原有的最后一项改为"AAAA"
D.把字符串"AAAA"插入到列表框的最前面(即"Item 1"的前面)
点击查看答案&解析
<上一题
目录
下一题>
热门
试题
单项选择题
下列程序运行时输出的结果是 Option Base 1 Private Sub Form_Click() Dim x (10)As Integer,y(5)As Integer For i=1 to 10 x(i)=10-i+1 Next For i=1 to 5 y(i)=x(2*i-1)+x(2*i) Next For i=1 to 5 Print y(i) Next End Sub
A.3 7 11 45 19
B.19 15 11 7 3
C.1 3 5 7 9
D.不确定的值
点击查看答案&解析
单项选择题
设已经在“菜单编辑器”中设计了窗体的快捷菜单,其顶级菜单为Bs,取消其“可见”属性,运行时,在以下事件过程中,可以使快捷菜单响应鼠标右键菜单的是
A.Private Sub Form_MouseDown(Button As Integer,Shift As Integer, X As Single,Y As Singl If Button=2 Then PopupMenu Bs,2 End Sub
B.Private Sub Form_Mouse Down(Button As Integer,Shift As Integer, X As Single,Y As Singl PopupMenu Bs End Sub
C.Private Sub Form_MouseDown(Button As Integer,Shift As Integer,_ X As Single,Y As Singl PopupMenu Bs,0 End Sub
D.Private Sub Form_MouseDown(Button As Integer,Shift As Integer,_ X As Single,Y As Singl If(Button=VbLeftBuaoOr(Button=VbRighButtoThen PopupMenu Bs End Sub
点击查看答案&解析
相关试题
有如下事件过程:Private Sub Form Acti...
下列程序的功能是:将数据1,2,..,8...
下列程序的功能是:当x<50时,y =0....
下列事件过程的功能是:建立一个名为Datal...
如果存在如下过程:Private Function Fun...