单选题
VB
2009-01-19
假定建立了一个名为Command1的命令按钮数组,则以下说法中错误的是( )。
A.数组中每个命令按钮的名称(名称属性)均为Command1
B.数组中每个命令按钮的标题(Caption属性)都一样
C.数组中所有命令按钮可以使用同~个事件过程
D.用名称Command1(T标)可以访问数组中的每个命令按钮
参考答案
B
答案解析
控件数组中的控件共用一个相同的控件名字,使用同一个事件过程,名称使用Index放在圆括号中,来访问每一个数组元素。如果不是使用复制、粘贴的方法来制作控件数组时,改变所有控件成为相同的名称,但其Caption不一定相同。
你可能感兴趣的试题
A.21
B.19
C.17
D.34
A.Private Sub Form_MouseDown(Button As Integer,Shift As Integer,X As Single,YAs Single) IfButton=2 Then PopupMenu al,2End Sub
B.Private Sub Form_MouseDown(Button As Integer, Shift As Integer,X As Single,Y As Single) PopupMenu al,0Fnd Sub
C.private Sub Form_MouseDown(Button As lnteger,Shift As_Integer,X As Single,Y As Single) PopupMenu a lEndSub
D.Private Sub Form_MouseDown(Button As Integer,Shift As eger,X As Single,YAs Single) If(Button=vbLetfButton)Or(Button=vbRightButton)Then PopupMenu alEndSub