Dim lvw As WinForm.ListView = e.Form.Controls("ListView3")
Dim vls As String = ""
Dim ary() As String = e.Form.DropDownBox.BindingField.Split(".")
Dim tr As Row = Tables(ary(0)).Current
Dim dr As DataRow = DataTables("Z005窗表字段设置").Find("[绑定表] ='"& ary(0) &"' And [绑定列] ='"& ary(1) &"' AND [绑定窗口名称]='通用目录树'")
If dr IsNot Nothing AndAlso dr.IsNull("绑定赋值列")=False AndAlso dr.IsNull("取值列")=False Then '如果在项目表找到对应的行
Dim Parts1() As String=dr("取值列").Split(",")
Dim Parts2() As String=dr("绑定赋值列").Split(",")
Dim vals(Parts1.length-1)
For Each vr As WinForm.ListViewRow In lvw.CheckedRows
Dim fdr As DataRow = DataTables(dr("取值表")).find("_Identify = " & vr.Name)
If fdr IsNot Nothing
For i As Integer = 0 To parts1.length-1
vals(i) &= fdr(parts1(i)) & ","
Next
End If
vls = vls & "," & vr.Text
Next
For i As Integer = 0 To parts2.length-1
tr(parts2(i)) = vals(i).Trim(",")
Next
e.Form.DropDownBox.Value = vls.Trim(",")
End If
e.Form.DropDownBox.CloseDropdown()