t;> 0 Then
adoprimaryrs1.MoveFirst
Else
Exit Sub
End If
Do Until adoprimaryrs1.EOF
TempSmallStyle = adoprimaryrs1.Fields("函数").Value
Set nodey = TreeView1.Nodes.Add(a, tvwChild, b, TempSmallStyle, 3, 3)
b = b + "1"
adoprimaryrs1.MoveNext
Loop
adoprimaryrs1.Close
Set adoprimaryrs1 = Nothing
Else
'*************************************************
adoprimaryrs1.CursorLocation = adUseClient
adoprimaryrs2.CursorLocation = adUseClient
adoprimaryrs1.Open "select distinct 小类别 from Code where 大类别='" & TempBigStyle & "'", StrConnect, adOpenForwardOnly, adLockReadOnly, adCmdText
'*************************************************
TreeView1.LineStyle = tvwRootLines
TreeView1.Nodes.Clear
Set nodex = TreeView1.Nodes.Add(, , a, TempBigStyle, 2, 1)
If adoprimaryrs1.RecordCount <> 0 Then
adoprimaryrs1.MoveFirst
Else
Exit Sub
End If
Do Until adoprimaryrs1.EOF
TempSmallStyle = adoprimaryrs1.Fields("小类别").Value
Set nodey = TreeView1.Nodes.Add(a, tvwChild, b, TempSmallStyle, 3, 3)
If adoprimaryrs2.State = 1 Then
adoprimaryrs2.Close
End If
adoprimaryrs2.Open "select 标题 from Code where 大类别='" & TempBigStyle & "' and 小类别='" & TempSmallStyle & "'", S
VB+教学辅助系统(四)相关范文