The requested page is not available for the requested platform. You are viewing the content for Default platform.

Y-Axis

The Y-axis is the numerical axis of values.

Chart_YAxis

To access Y-axis settings, use the Y-Axis Settings button in the Diagram section of the Design Ribbon tab of the Chart Tools contextual tab set.

Chart_YAxisOptions_Button

This will invoke the Y-Axis Settings dialog.

Chart_YAxisOptions_Form

Use the combo box at the top to select the pane for the Y-axis settings you need to edit.

Common Settings

The Common tab contains the following settings.

Always show zero level

Specifies whether the axis' zero level is visible. If this option is unchecked, the visible axis range is defined based on the values plotted in the chart.

Chart_YAxisOptions_AlwaysShowZeroLevel

Reverse

Allows you to reverse the Y-axis. If the Y-axis is reversed, its values are ordered from top to down.

Show grid lines

Allows you to hide and show grid lines for the Y-axis.

Show Y-axis

Allows you to hide and show the Y-axis.

Show title

Allows you to hide and show the Y-axis title. You can choose whether to use the default text or specify a custom string.

Logarithmic scale

Specifies whether the axis should display its numerical values using a logarithmic scale. The combo box next to this option allows you to select the logarithmic base from one of the predefined values.

To access Y-axis settings in code, use the ChartPane.PrimaryAxisY property. The returned ChartAxisY object exposes the following properties.

ChartAxisY.AlwaysShowZeroLevel

Gets or sets whether the zero level of the Y-axis should always be visible.

ChartAxisY.Logarithmic

Gets or sets whether the axis should display its numerical values using a logarithmic scale.

ChartAxisY.LogarithmicBase

Gets or sets a value specifying a logarithmic base when the ChartAxisY.Logarithmic property is enabled.

ChartAxis.Reverse

Gets or sets whether the axis is reversed.

ChartAxisY.ShowGridLines

Gets or sets whether to show grid lines for a Y-axis.

ChartAxis.Visible

Gets or sets whether the chart's axis is visible.

ChartAxis.TitleVisible

Gets or sets whether the title of the chart's axis is visible.

ChartAxis.Title

Gets or sets the title of the chart's axis.

The Numeric Format tab allows you to specify the numeric display formats for Y-Axis data, as described in the Formatting Data document. In code, you can use the ChartAxisY.NumericFormat property.

Chart_YAxisOptions_NumericFormat

The tab contains the following settings.

Format type

Specifies format types for numeric values. Available types are listed in the DataItemNumericFormatType enumeration.

Unit

Specifies the unit to convert the numeric values. Available types are listed in the DataItemNumericUnit enumeration.

Precision

Specifies the number of fractional digits to display.

Currency

Specifies the currency symbol and format provided by the RegionInfo class.

Culture

Specifies the name of a culture that defines the currency symbol and format.

Include group separator

Specifies whether separators should be inserted between digit groups.

Secondary Y-Axis

The secondary Y-axis is useful when it is necessary to visually combine several charts into one. Secondary axes provide the ability to plot series with different ranges on the same chart.

Chart_secondaryYAxis

To plot the required series using the secondary axis, enable the Plot on secondary axis option in the Series Options dialog.

Charts_SeriesOptions_CommonOptions_Cut

In code, use the ChartSeries.PlotOnSecondaryAxis property.

Note

Note that the Y-Axis Settings dialog allows you to specify settings for primary and secondary axes separately.