Listview control tag and key property

surezhp

New member
Joined
Sep 8, 2006
Messages
1
Programming Experience
Beginner
How do i store the primary key in a listview tag or key property. I want to store the id in one property and load the item in list view like listbox.itemdata and listbox.additem in vb6.


How can i do that?

Please any one can help me?

Regards,
SureshP
 
A ListView control has an Items property. It is a collection of ListViewItem objects, each of which has a Tag property. You need create ListViewItem objects and assign your additional data to their Tag properties, then add them to the ListView. The documentation for the ListView class is the place to start.

http://msdn2.microsoft.com/en-us/library/system.windows.forms.listview.aspx
 
Back
Top