# Dbcombo控制项

Posted by airbird on September 22, 1997 at 03:34:34:

请问为什么我用"Tab键"去选择Dbcombo控制项
中的资料,Dbcombo与Dblist的栏位无法对应?
我有在Dbcombo的click事件中写:
Dim cn As rdoConnection
Static temp1, temp2, temp3 As Variant
If DBCombo1.Text = temp2 Then Exit Sub
temp2 = DBCombo1.Text
Dim rsTemp As rdoResultset
Set cn = MSRDC1.Connection
Set rsTemp = cn.OpenResultset(" select 栏位 from 资料库" _
& " where 栏位 = '" & temp2 & "' ", _
rdOpenKeyset)
Set MSRDC1.Resultset = rsTemp
temp3 = MSRDC1.Resultset!栏位
MSRDC2.SQL = " select 栏位 from 资料库 " _
& " where 栏位 = '" & temp3 & "' "
MSRDC2.Refresh

Dbcombo1--Msrdc1
Dblist1--Msrdc2

Follow Ups:

- Tab 键? 小吴 17:45:04 9/24/97 (0)