Quick and easy question on construction.
I have the following code for adding an Item to a list view.
ListViewItem item = new ListViewItem();
item.Text = file;
item.SubItems.Add("Un-Tested");
lvJourneys.Items.Add(item);
However I wish to use code more similar to the following, but i’m unable to find the correct syntax,
lvJourneys.Items.Add(new ListViewItem(file, "Un-Tested"));
Appreciate any help.
You just need to make your own custom constructor like such: