Главная страница | назад

Article #19578: TListView and Multiple Columns

 Question and Answer Database

FAQ4578C.txt - TListView and Multiple Columns

Category   :VCL
Platform   :All Windows
Product    :All-CBuilder,   

How can I add items to a TListView containing more than one column?

For any give line in a TListView, you can add items to the next column
by using the SubItems property.  For example...

    TListItem *MyItem = ListView1->Items->Add();
    MyItem->Caption = "First Column Item";
    MyItem->SubItems->Add("Second Column Item");
    MyItem->SubItems->Add("Third Column Item");

5/25/99 11:47:36 AM

Last Modified: 01-SEP-99