Jump to content
Software FX Community
Sign in to follow this  
User (Legacy)

GetLegend event doesn't work (delphi 4)

Recommended Posts

I need the numbers shown in Y axis legend converted to currency format. I 

thought that GetLegend event handler is the right place to do that, but

following code doesn't work. Handler is properly called, but changing hText

parameter value has no effect on the chart. I'm using Delphi 4C/S and

ChartFX 2.0.0 (as shown in 'About' dialog). Any help?

somewhere in the initialization code:

...

chart.XLegType := CL_GETLEGEND;

...

procedure TMaskeAnalyse.chartGetLegend(Sender: TObject; nType: Smallint;

var nRes: Smallint);

var

v : real;

s : string;

begin

v := StrToFloat(chart.HText);

s := FloatToStrF(v, ffNumber, 14, 2);

chart.HText := s;

chart.ReturnValue := 1; //undocumented, doesn't help anyway..

nRes:= 1;

end;

thanks

--

Kristof

bengal *at* o2.pl

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...