Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
I have a listview with three columns and i have added 4 records in the listview.
I would like to get the value of the 2nd column value of each records.How to implement it?
Posted 17-Aug-12 8:32am
Comments
Kenneth Haugland at 17-Aug-12 13:43pm
   
WinForm or WPF, It dosent really matter if is binded in code behind though.
Shankar23G at 17-Aug-12 13:46pm
   
I can't understand what you said?
Wes Aday at 17-Aug-12 14:08pm
   
What is it that you have tried?

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

you can try this code
 
int i=0;
while (i < listView1.SelectedItems.Count)
{
               x = listView1.Items[i].SubItems[1].Text.ToString();
               i++;
}
 
Try and revert back
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 8,478
1 OriginalGriff 6,516
2 Peter Leow 3,567
3 Zoltán Zörgő 3,386
4 Richard MacCutchan 2,397


Advertise | Privacy | Mobile
Web01 | 2.8.150123.1 | Last Updated 19 Aug 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100