TLineSeries *Series = new TLineSeries(Chart);
// Create a new custom vertical axis
TChartAxis *vertaxis = new TChartAxis(Chart);
// Assign custom vertical axis
Series->CustomVertAxis = vertaxis;
// Set axis position
vertaxis->PositionPercent = 0; //percentage
// Set axis size
vertaxis->StartPosition = 10; //percentage
vertaxis->EndPosition = 50; //percentage
TChartAxis *horiaxis = new TChartAxis(Chart);
// Set new axis as horizontal
horiaxis->Horizontal = true;
Series->CustomHorizAxis = horiaxis;
horiaxis->PositionPercent = 0;
horiaxis->StartPosition = 30;
horiaxis->EndPosition = 60;
// Add line series to chart
Chart->AddSeries(Series);
No comments:
Post a Comment