Skip to main content
All docs
V24.2

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

TdxChartCustomSecondaryAxisCollectionItem.Title Property

Specifies the axis title, and its appearance and position.

#Declaration

Delphi
property Title: TdxChartAxisTitle read; write;

#Property Value

Type Description
TdxChartAxisTitle

Stores an axis title and its settings.

#Remarks

Use the Title.Text property to specify the axis title. Title.Appearance and Title.Position properties define the title’s appearance and position, respectively.

Refer to the TdxChartAxisTitle class description for detailed information on all available options.

#Code Example: Add a Secondary Axis

The following code example creates a secondary axis of values and associates it with the first series in an XY diagram:

var
  ADiagram: TdxChartXYDiagram;
  AAxisY: TdxChartSecondaryAxisYCollectionItem;
  AXYSeries: TdxChartXYSeries;
begin
  if dxChartControl1.DiagramCount = 0 then Exit;
  ADiagram := dxChartControl1.Diagrams[0] as TdxChartXYDiagram;
  if ADiagram.SeriesCount = 0 then Exit;
  AXYSeries := ADiagram.Series[0];
  AAxisY := ADiagram.SecondaryAxes.AxesY.Add;
  AXYSeries.View.AxisY := AAxisY.Axis;
  AAxisY.Title.Text := 'Income (USD)';
  AAxisY.Title.Alignment := TdxAlignment.Center;
  AAxisY.Appearance.Color := TdxAlphaColors.Gray;
end;
See Also