Lemy
Hero Member
    
Offline
Beiträge: 605

|
 |
« Antworten #1 am: 08.03.2002, 14:16:18 » |
|
[font size=2 face="Courier New" color="#000000"]Here is the example from the Delphi-Help:
procedure TForm1.FormCreate(Sender: TObject); const Names: array[0..5, 0..1] of ShortString = ( ('Domino', 'Fats'), ('Wagner', 'Richy'), ('Mozart', 'Wolferl'), ('Bach', 'Jockel'), ('Beethoven', 'Lucky'), ('Strauß', 'Johnny') );
var I: integer; NewColumn: TListColumn; ListItem: TListItem; ListView: TListView; begin ListView := TListView.Create(Self); with ListView do
begin Parent := Self; Align := alClient; ViewStyle := vsReport;
NewColumn := Columns.Add; NewColumn.Caption := 'Letzter'; NewColumn := Columns.Add; NewColumn.Caption := 'Erster';
for I := 0 to High(Names) do begin ListItem := Items.Add; ListItem.Caption := Names[0]; ListItem.SubItems.Add(Names[1]); end; end; end; [/font]
|