TLegendScrollBar problems

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
trydal
Newbie
Newbie
Posts: 9
Joined: Fri Mar 18, 2005 5:00 am

TLegendScrollBar problems

Post by trydal » Fri Aug 26, 2005 8:47 am

Hi again.

I'm having problems adding the TLegendScrollBar at runtime.

Creation:
Self.FLegendScrollBar := TLegendScrollBar.Create(self);
Self.FLegendScrollBar.ParentChart := self;
Self.Tools.Add(Self.FLegendScrollBar);

Segfaults when the legend becomes visible (when I insert the first line) in:

procedure TLegendScrollBar.LegendCalcSize(Sender:TCustomChartLegend; var ASize:Integer);
begin
if Active and ShouldDraw(R) then // SegFault
Inc(ASize,Size+1);
end;

R = (-14680065, -14680065, -14680065, -14680065, (-14680065, -14680065), (-14680065, -14680065))

Anyone here that have had simililar problems or know how to fix this?

Regards
Frode

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Fri Aug 26, 2005 9:04 am

Hi Frode,

It works fine here using code below and latest TeeChart version available. Does this code works for you? Could you please modify it so that or send an example we can run "as-is" to reproduce the problem here? You can post your files at [url]news://www.steema.net/steema.public.attachments[/url] newsgroup.

Code: Select all

procedure TForm1.FormCreate(Sender: TObject);
var
  LegendScroll: TLegendScrollBar;
begin
  LegendScroll:=TLegendScrollBar.Create(self);
  LegendScroll.ParentChart:=Chart1;

  Series1.FillSampleValues(50);
end;
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply