C# listview.add

                listview.Add(null);
                DataRow[] row= getdatarow();
                if (row.Length > 0)
                {
                    for (int i = 0; i < row.Length; i++)
                        listview.Add(new Frm(i + 1, row[i]["string"].ToString()));
                }
                this.combobox.DataSource = listview
                this.combobox.DisplayMember = "string";

                this.combobox.ValueMember = "string";

原文地址:https://www.cnblogs.com/liye/p/1785511.html