How to retrieve values from ListView ?

Oct 8 2011 6:19 AM
I want to retrieve value from ListView Control named here as Product_listViewFF. When the user selects a row from ListView value of the first column in first row must be read.


When I used:- Product_listViewFF.SelectedItems[0].SubItems[0].Text

It works well when i select the row first time. But when i again select some other row it throws error as "InvalidArgument=Value of '0' is not valid for 'index' "

Can somebody why error occured on selecting the row second time and not on the first time?



Answers (4)