下拉窗口的afterload事件为:Dim Products As List(Of String)
Products = DataTables("Table_JieSuan").SQLGetValues("ShouKuanTitle")
Dim lvw As WinForm.ListView = e.Form.Controls("ListView1")
lvw.StopRedraw() '暂停绘制
lvw.View = ViewMode.SmallIcon '显示模式为小图标
For Each Product As String In Products
'Dim Key As String = dr("图标")
Dim r As WinForm.ListViewRow = lvw.Rows.Add() '增加一行
lvw.Images.AddSmallImage("Man", "Man48.ico") '添加代表这个国家的小图标
r.ImageKey = "Man" '指定图标键值
r.Text = product
r.Tag = Products '将对应的Datarow赋值给tag属性,方便在其他事件中调用
Next
lvw.ResumeRedraw() '恢复绘制
listview1控件的RowActivate事件中的代码应该如何写能实现双击某条记录自动填充其他字段值。(下面代码报错:可能跟TAG属性有关)
Dim lvw As WinForm.ListView = e.Sender
Dim dr As DataRow = lvw.Current.tag
Dim r As Row = e.Form.DropTable.Current
r("YiYuanName") = dr("YiYuanName")
e.Form.DropDownBox.Value = dr("ShouKuanTitle")
e.Form.DropDownBox.CloseDropdown()