Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2014-03

TAChart stopped working

2 messages · 1 person · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Marc Santhoff

Hi,

while running a program using TAChart with a newer version of Lazarus (1.0.10 or 1.0.14) and fpc 2.6.2 an exception "ERangeError" is thrown. The program dates before Lazarus 1.0.10 and worked flawlessly then.

The error occurs in line 1103 of TACustomSeries:

<code>
procedure TBasicPointSeries.PrepareGraphPoints(
  const AExtent: TDoubleRect; AFilterByExtent: Boolean);
...
  SetLength(FGraphPoints, FUpBound - FLoBound + 1);
  if (AxisIndexX < 0) and (AxisIndexY < 0) then
...
</code>

when SetLength is called.

I'm using 4 UserDefinedChartSeries for drawing 4 graphs. The PointsNumber is 256. When SetLenght is called, in FGraphPoints does have approriate contents, FUpBound is 0 and FLoBound is 255.

Before I document the complete workings of my program I'd like to ask: Has there been any change making this one a known issue?

TIA,
Marc

Marc Santhoff

Reply by email

Marc Santhoff
to Marc Santhoff

Replying to myself:

Marc Santhoff wrote 25 lines
Hi, while running a program using TAChart with a newer version of Lazarus (1.0.10 or 1.0.14) and fpc 2.6.2 an exception "ERangeError" is thrown. The program dates before Lazarus 1.0.10 and worked flawlessly then. The error occurs in line 1103 of TACustomSeries: <code> procedure TBasicPointSeries.PrepareGraphPoints( const AExtent: TDoubleRect; AFilterByExtent: Boolean); ... SetLength(FGraphPoints, FUpBound - FLoBound + 1); if (AxisIndexX < 0) and (AxisIndexY < 0) then ... </code> when SetLength is called. I'm using 4 UserDefinedChartSeries for drawing 4 graphs. The PointsNumber is 256. When SetLenght is called, in FGraphPoints does have approriate contents, FUpBound is 0 and FLoBound is 255. Before I document the complete workings of my program I'd like to ask: Has there been any change making this one a known issue?

Actually there have been lots of changes since 1.0.10. A new (short) test using laz 1.2 works flawlessly.

Thanks for the effort, fpc + lazarus is still the best thing one can get. :)

Marc Santhoff

Reply by email