Newbie question concerning TChartAxis

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
Ingman
Newbie
Newbie
Posts: 3
Joined: Wed Sep 22, 2004 4:00 am
Location: Sweden

Newbie question concerning TChartAxis

Post by Ingman » Tue Sep 13, 2005 12:13 pm

Hi,

I would like to create AChart that has one TLineSeries and a TBarSeries as well, the left axis should display for example count and the right axis percent, that is two different scales. Is this possible to do? If not I could standardize the two series, so they are shown relative the axis length, but as it is now I cant even get the left axis to show any scale or label. I would be grateful for any ideas how to make this work.

/Ingman

Ingman
Newbie
Newbie
Posts: 3
Joined: Wed Sep 22, 2004 4:00 am
Location: Sweden

Problem solved, but new problem with labels position

Post by Ingman » Wed Sep 14, 2005 8:29 am

Hi again,

solved that problem using the following modified helpfile example:

procedure TForm1.Button1Click(Sender: TObject);
var
tmpVertAxis: TChartAxis;
begin
// Add vertical Axis
Chart1.CustomAxes.Add;
tmpVertAxis:=Chart1.CustomAxes[0];
tmpVertAxis.PositionPercent:=100;
Series2.CustomVertAxis:=tmpVertAxis;
end;

And this works fine, except that the labels on my new custom vertical axis is printed to the left of the axis which has the effect that they are in the chart area, does anyone know how to make the labels appear on the right side of the axis?

/Ingman

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

Post by Narcís » Wed Sep 14, 2005 9:01 am

Hi Ingman,
And this works fine, except that the labels on my new custom vertical axis is printed to the left of the axis which has the effect that they are in the chart area, does anyone know how to make the labels appear on the right side of the axis?
Yes, you could use:

Code: Select all

tmpVertAxis.OtherSide:=true;
instead of using PositionPercent.
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

Ingman
Newbie
Newbie
Posts: 3
Joined: Wed Sep 22, 2004 4:00 am
Location: Sweden

Post by Ingman » Wed Sep 14, 2005 9:32 am

That worked, excelllent :D

Post Reply