I am trying to retrieve the data that is in a listviews subitems.
I would have thought something like this would be the answer, but I cant find anything similar to it.
var test = radListView1.Items[2].SubItems[2].Value
Where am I going wrong?
8 Answers, 1 is accepted
Thank you for your question.
You can find the answer to your question in this help article, under the section 'Populating cells'.
I hope you find it useful. Feel free to ask if you have any additional questions.
Best wishes,
Ivan Todorov
the Telerik team
Q2’11 SP1 of RadControls for WinForms is available for download (see what's new); also available is the Q3'11 Roadmap for Telerik Windows Forms controls.

Hi,
How i update row/cell value in radlistview ?
br,
Džemal
If your RadListView is in bound mode, you can directly update the DataBoundItem. However, if you use unbound mode, you can access the desired cell. You can set cell values to the items of RadListView using their indexers. The keys can be either the index of the column, the name of the column, or the column itself. Please refer to the following help article: https://docs.telerik.com/devtools/winforms/listview/populating-with-data/unbound-mode
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Dess
Progress Telerik

Hello,
How can I control duplicate item on radlistview1 ? How can I find item by text ?
Thank you,
Džemal

I'm talking about Windows form. Otherwise, very little documentation for radlistview control.
Best regards,
Džemal
In order to find a specific item by text, you can iterate the Items collection and check which item's text meets the search criteria. As to the documentation, we strive to cover the common features that the RadListView supports and the public API it exposes. Any feedback about what should be included in the documentation as well will be greatly appreciated.
ListViewDataItem searchResult =
null
;
foreach
(ListViewDataItem item
in
this
.radListView1.Items)
{
if
(item.Text ==
"Ikura"
)
{
searchResult = item;
break
;
}
}
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Dess
Progress Telerik

Hello,
Thank you.
I worked on default lists:
foreach (ListViewItem item in listView1.Items)
{
var invoice = item.SubItems[1];
if (invoice.Text == "whatever")
{
item.SubItems[2] = new ListViewItem.ListViewSubItem()
{
Text = "Paid"
};
break;
}
}
how do I update on the list as on the line:
item.SubItems[2] = new ListViewItem.ListViewSubItem()
{
Text = "Paid"
};
Best regards,
Džemal
According to the attached screenshot it seems that you use Details View in RadListView. The following help article demonstrates how to add columns and specify the cells' values: https://docs.telerik.com/devtools/winforms/listview/populating-with-data/unbound-mode
You can set cell values to the items of RadListView using their indexers. The keys can be either the index of the column, the name of the column, or the column itself.
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Dess
Progress Telerik