Dim dr As SqlDataReader = cmd.ExecuteReader
Me.ListView1.Items.Clear()
Do While dr.Read
With Me.ListView1
.Items.Add(dr(0))
With .Items(.Items.Count - 1).SubItems
.Add(dr.Item(1))
.Add(dr.Item(2))
.Add(dr.Item(3))
End With
End With
Loop
dr.Close()
Me.Show()
Me.ListView1.Columns.Add("Account ID", 100)
Me.ListView1.Columns.Add("Managed by", 100)
Me.ListView1.Columns.Add("Account Holder", 100)
Me.ListView1.Columns.Add("Description", 100)
'Public Function Add(text As String)As System.Windows.Forms.Listviewitem.Listview.Subitems)As System.Windows.Forms.Listviewitem.Listview.Subitem':参数匹配参数项无法从 DBNull 转换为 ListViewSubitems