void GetItem() { ItemC items = new ItemC(); foreach (Item item in items.GetItem()) { cbitem.Items.Add(item.Name + "," + item.Size + "," + item.Type); } }
void ShowItemListAsListView() { var items = new ItemC(); lvitem.Items.Clear(); foreach (Item item in items.GetItem()) { var t = new ListViewItem(item.Id.ToString()); t.SubItems.Add(item.Name); lvitem.Items.Add(t); tbitem.Text = ""; cbtype.Text = ""; tbsize.Text = ""; cbsize.Text = ""; tbcode.Text = ""; btnitemnew.Text = "New"; DisenableItem(); } }