Jump to content
Software FX Community

Multi Series Labels


Recommended Posts

hi,

I have a question about multi series labeling in a line chart. the labels for the axis_x
are numbers instead of the string read from the dataset

This only
happens for multi series ........single series is ok.
Please let me know how i can rectify this. Thanks!

 

Posted Image
 

 

 

Link to post
Share on other sites

I'm using ChartFX CS 5.1 for Delphi 6.

 

IN THE MAIN FUNCTION

  /* yvaluesABS : array[1..128] of double; */

  /* sitenames : array[1..15] of string;  */

    /* CfxData: CfxDataArray; */

//assign values to yvaluesABS  and sitenames

//....


  CfxData := CfxDataArray.Create();

  for i := 0 to 14 do
  begin
  for j := 0 to 127 do
  yvaluesABS[j] := /* assign values to yvaluesABS */;
  CfxData.AddArray(yvaluesABS);
  ChartP.Series.Legend := sitenames;
  end;
  ChartP.Title[CHART_TOPTIT] := '....';

  ChartP.Axis[axis_y].ForceZero := false;
  ChartP.Axis[axis_y].AutoScale := true;
  ChartP.Axis[axis_x].STEP := 0;

  ChartP.GetExternalData(CfxData.InterfacePtr,0);

 

AND THEN IN A CLICK EVENT TO CHANGE LABELS OF CHARTP: 

  /*  itv_bandname : array[1..128] of string;  */

  //assign values to itv_bandname

  //...

  for f:= 0 to 127 do
  ChartP.Axis[AXIS_X].Label_[f] := itv_bandname[f];

 

 

 

thanks! 

Link to post
Share on other sites
  • 2 weeks later...

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...
×
×
  • Create New...