Export (0) Print
Expand All
Expand Minimize

_Chart.ChartWizard Method

Modifies the properties of the given chart. You can use this method to quickly format a chart without setting all the individual properties. This method is non-interactive, and it changes only the specified properties.

Namespace:  Microsoft.Office.Interop.Excel
Assembly:  Microsoft.Office.Interop.Excel (in Microsoft.Office.Interop.Excel.dll)

void ChartWizard(
	Object Source,
	Object Gallery,
	Object Format,
	Object PlotBy,
	Object CategoryLabels,
	Object SeriesLabels,
	Object HasLegend,
	Object Title,
	Object CategoryTitle,
	Object ValueTitle,
	Object ExtraTitle
)

Parameters

Source
Type: System.Object
Optional Object. The range that contains the source data for the new chart. If this argument is omitted, Microsoft Excel edits the active chart sheet or the selected chart on the active worksheet.
Gallery
Type: System.Object
Optional XlChartType. The chart type.
Format
Type: System.Object
Optional Object. The option number for the built-in autoformats. Can be a number from 1 through 10, depending on the gallery type. If this argument is omitted, Microsoft Excel chooses a default value based on the gallery type and data source.
PlotBy
Type: System.Object
Optional Object. Specifies whether the data for each series is in rows or columns. Can be one of the following XlRowCol constants: xlRows or xlColumns.
CategoryLabels
Type: System.Object
Optional Object. An integer specifying the number of rows or columns within the source range that contain category labels. Legal values are from 0 (zero) through one less than the maximum number of the corresponding categories or series.
SeriesLabels
Type: System.Object
Optional object. An integer specifying the number of rows or columns within the source range that contain series labels. Legal values are from 0 (zero) through one less than the maximum number of the corresponding categories or series.
HasLegend
Type: System.Object
Optional Object. True to include a legend.
Title
Type: System.Object
Optional Object. The chart title text.
CategoryTitle
Type: System.Object
Optional Object. The category axis title text.
ValueTitle
Type: System.Object
Optional Object. The value axis title text.
ExtraTitle
Type: System.Object
Optional Object. The series axis title for 3-D charts or the second value axis title for 2-D charts.

If Source is omitted and either the selection isn't an embedded chart on the active worksheet or the active sheet isn't an existing chart, this method fails and an error occurs.

Community Additions

ADD
Show:
© 2014 Microsoft