procedure TMultiAxisScroll.FormCreate(Sender: TObject);
begin
inherited;
Series1.FillSampleValues(100);
Series2.FillSampleValues(100);
Series3.FillSampleValues(100);
Series4.FillSampleValues(100);
{ change the Left axis properties }
With Chart1.LeftAxis do
begin
Axis.Color:=clRed;
StartPosition:=0;
EndPosition:=33;
end;
{ create custom axes. This can be done at design-time
with the chart editor. }
Green:=TChartAxis.Create(Chart1.CustomAxes);
With Green do
begin
Axis.Color:=clGreen;
StartPosition:=33;
EndPosition:=66;
end;
Blue:=TChartAxis.Create(Chart1.CustomAxes);
With Blue do
begin
Axis.Color:=clBlue;
StartPosition:=66;
EndPosition:=100;
end;
{ associate series }
Series1.VertAxis:=aLeftAxis;
Series2.VertAxis:=aLeftAxis;
Series3.CustomVertAxis:=Green;
Series4.CustomVertAxis:=Blue;
end;