VB Combo和List怎么连在一起,比如我选择第一项list里显示不同的内容,第二项又显示不同的内容,怎么做啊
来源:百度知道 编辑:UC知道 时间:2024/08/21 02:05:20
新建一个文本文档,将下面代码复制到新建的文本文档里面,修改文本文档名字为:form1.frm,然后用vb6.0编译器打开,运行之。。。
VERSION 5.00
Begin VB.Form Form1
Caption = "Form1"
ClientHeight = 5025
ClientLeft = 60
ClientTop = 450
ClientWidth = 6990
LinkTopic = "Form1"
ScaleHeight = 5025
ScaleWidth = 6990
StartUpPosition = 3 '窗口缺省
Begin VB.ComboBox Combo1
Height = 300
Left = 960
TabIndex = 1
Text = "Combo1"
Top = 840
Width = 2535
End
Begin VB.ListBox List1
Height = 3480
Left = 4680
TabIndex = 0
Top = 720
Width = 1335
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Sub Combo1_Click()
Select Case Combo1.Text
Case "第一项"
L