Sin sie habs geprüft.
Außerdem hab ich mal nur die Range sachen auskommentiert, dann läuft alles wunderbar, werst wenn ich die wieder einkommentier krachts.
Hier noch der code der die LineSeries erstellt
Code: Alles auswählen
setlength(graphen, Anzahl);
abstand := round((16777215) / Anzahl + 20);
r := 0;
g := 0;
b := 0;
c := 0;
for i := 0 to high(graphen) do
begin
graphen[i] := TLineSeries.Create(Chart1);
Chart1.AddSeries(graphen[i]);
graphen[i].LinePen.Width := 2;
c := c + abstand;
tmp := inttohex(c, 6);
r := StrToInt('$' + copy(tmp, 1, 2));
g := StrToInt('$' + copy(tmp, 3, 2));
b := StrToInt('$' + copy(tmp, 5, 2));
graphen[i].LinePen.Color := RGB2TColor(r, g, b);
ini := TInifile.Create(ExtractFilePath(ParamStr(0)) + 'gui.ini');
try
pagecount := ini.ReadInteger('Info', 'Anzahl', 0);
j := 0;
title := '';
while (j <= pagecount) and (title = '') do
begin
labelcount := ini.ReadInteger('Page' + IntToStr(j), 'LabelAnzahl', 0);
if i <= labelcount then
title := ini.ReadString('Page' + IntToStr(j), 'Label' + IntToStr(i), '');
Inc(j);
end;
finally
ini.Free
end;
graphen[i].Title := title;
end;