Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ListView Question

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
I have 3 columns in a ListView, how do I access the data in say the first field and put it in a Tedit component?
 
This Should get you started - lets assume your listview
is named TestView. This code accesses the caption of the second item - listview items start at 0. It puts the caption in an edit box. If you dont want the caption, play around with the drop down list of attributes.



TListItem *ListItem;
ListItem = TestView->Items->Item[1];
Edit1->Text = ListItem->Caption;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top