如何用COMBOBOX来控制
请问一下如何使用COMBOBOX 的选项来控制其它控件的VISABLE属性?
比如:我想让COMBO1.LISTINDEX = 1 隐藏一个TEXT1
COMBO1.LISTINDEX = 2 显示TEXT1 隐藏TEXT2
应该如何编程实现?
[解决办法]
if Combo1.ListIndex> =0 then 'selected one
for i=0 to Combo1.ListIndex-1
Text(i).Visible = true
next i
Text(Combo1.ListIndex).Visible = false
for i=Combo1.ListIndex+1 to text1.Count - 1
Text(i).Visible = true
next i
else
'Combo no selected
for i=0 to text1.Count - 1
Text(i).Visible = true
next i
end if