moin
hier der Code:
Delphi-Quellcode:
procedure TForm1.rebuild_list();
var
I: Integer;
tmpC : String;
tmpX1: String;
tmpY1: String;
tmpX2: String;
tmpY2: String;
tmpX3: String;
tmpY3: String;
begin
for I := 0 to points.Items.Count do
begin
points.Items[i].Caption := IntToStr(I+1);
if I = 0 then
begin
points.Items.Item[I].SubItems[1] := '0';
points.Items.Item[I].SubItems[2] := '0';
end
else
begin
if points.Items.Item[I-1].SubItems[0] = 'Bogen' then
begin
points.Items.Item[I].SubItems[1] := tmpX3;
points.Items.Item[I].SubItems[2] := tmpY3;
end
else if points.Items.Item[I-1].SubItems[0] = 'Linie' then
begin
points.Items.Item[I].SubItems[1] := tmpX2;
points.Items.Item[I].SubItems[2] := tmpY2;
end
else
begin
points.Items.Item[I].SubItems[1] := tmpX2;
points.Items.Item[I].SubItems[2] := tmpY2;
end;
end;
tmpC := points.Items.Item[I].SubItems[0];
tmpX1 := points.Items.Item[I].SubItems[1];
tmpY1 := points.Items.Item[I].SubItems[2];
tmpX2 := points.Items.Item[I].SubItems[3];
tmpY2 := points.Items.Item[I].SubItems[4];
tmpX3 := points.Items.Item[I].SubItems[5];
tmpY3 := points.Items.Item[I].SubItems[6];
points.Items.Item[I].SubItems[0] := tmpC;
points.Items.Item[I].SubItems[3] := tmpX2;
points.Items.Item[I].SubItems[4] := tmpY2;
points.Items.Item[I].SubItems[5] := tmpX3;
points.Items.Item[I].SubItems[6] := tmpY3;
end;
end;
so immer wenn ich diese procedure aufrufe, kommt dieser fehler:
http://www.imagespell.com/show.php?i...7a46763717.jpg
woran liegt das?
MfG