R
riche
Unregistered / Unconfirmed
GUEST, unregistred user!
const
Names:array[0..5,0..1] of string =(('Rubble','Barney'),('Michael','Johnson'),
('Bunny','Bugs'),('Silver','Hiho'),('Simpson','Bart'),('Squirrel','Rockey'));
var
i:integer;
NewColum: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:='Last';
NewColumn:=Columns.add;
NewColumn.Caption:='First';
for i:=low(Names)to high(Names) do
begin
ListItem:=Items.Add;
Listitem.Caption:=Names[0];
ListItem.SubItems.Add(Names[1]);
end;
end;
end;
end;
我在编译时通不过,请教高手是什么原因,请指教。
Names:array[0..5,0..1] of string =(('Rubble','Barney'),('Michael','Johnson'),
('Bunny','Bugs'),('Silver','Hiho'),('Simpson','Bart'),('Squirrel','Rockey'));
var
i:integer;
NewColum: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:='Last';
NewColumn:=Columns.add;
NewColumn.Caption:='First';
for i:=low(Names)to high(Names) do
begin
ListItem:=Items.Add;
Listitem.Caption:=Names[0];
ListItem.SubItems.Add(Names[1]);
end;
end;
end;
end;
我在编译时通不过,请教高手是什么原因,请指教。