add new Line to the chart

guzialguzial Poland
edited 1:49AM in FastReport 3.0
hello,

i need to add new line to Chart object in my report.
I is easy to add new line during design but i want to add new line at run time by fastScript

thanks for help

Comments

  • edited 1:49AM
    it,s not possible.
    You can't add series in scipt, because necessary property not registred in script.
  • guzialguzial Poland
    edited October 2006
    so how to do it in Delphi?
    i made
    procedure TDMNivo.frxReport1BeginDoc(Sender: TObject);
    var
     ? komp : TfrxChartView;
     ? seria : array [0..2] of tchartSeries;
    
    begin
     ? komp := TfrxChartView(frxReport1.FindObject('Chart1'));
     ? seria[0] := TChartSeries.Create(komp);
     ? seria[1] := TChartSeries.Create(komp);
     ? seria[2] := TChartSeries.Create(komp);
     ? komp.Chart.AddSeries(seria[0]);
     ? komp.Chart.AddSeries(seria[1]);
     ? komp.Chart.AddSeries(seria[2]);
     ? //komp.Chart.
     ? showmessage(inttostr(komp.Chart.SeriesCount));
    end;
    

    so it works but i don't know if corret
    seriesCount shows that number of series rise up, but it i don't know how to change type of series (line, bar etc) colour etc
  • edited 1:49AM
    I attach example.
  • guzialguzial Poland
    edited 1:49AM
    i will check ;)
    thanks a lot
  • guzialguzial Poland
    edited 1:49AM
    ok it works,

    could write me how can i change property of each line - its called in designer as "X axis" and it can take one of value "text" "date" "numeric"
  • guzialguzial Poland
    edited 1:49AM
    ok i found out ;) )
    its Xtype and values : xtText, xtNumber, xtDate
  • edited 1:49AM
    wrote: »
    I attach example.

    Hi i can't download the attachment. So please can you reup the file.

    Thx in advance.
  • edited 1:49AM
    madas wrote: »

    Hi i can't download the attachment. So please can you reup the file.

    Thx in advance.


    Plus one for me .. looking into a similar problem and any example code would be great ...
  • gordkgordk St.Catherines On. Canada.
    edited 1:49AM
    you must be logged into the forums as a member not as a guest to download
  • edited 1:49AM
    gordk wrote: »
    you must be logged into the forums as a member not as a guest to download

    As you can see ... I'm logged in ...yet download generates a forum error ... >
  • edited 1:49AM
    It is possible to upload an example to another server, because here nobody can download it ?!
  • edited 1:49AM
    Now you can download it. Try again.
  • edited 1:49AM
    ok Can be downloaded, and I first went to study. >

Leave a Comment