Dim str As String Dim Frm As WinForm.Form = Forms("信息查询") If frm.Opened AndAlso Tables("信息查询_tabResult").Rows.Count > 0 Then str = Tables("信息查询_tabResult").Current("品类编号") Dim dt As DataTable = DataTables("业态分类表") Dim r As DataRow r = dt.Find("[品类编号] = '" & str & "'") If r IsNot Nothing Then Frm.Controls("txtClass").Text = r("大类").SubString(1) & "/" & r("业态").SubString(1) & "/" & r("业种").SubString(2) & "/" & r("品类").SubString(2) Else Frm.Controls("txtClass").Text = Nothing End If End If
|