Table of contents
Collapse the table of content
Expand the table of content

Chart.SetDefaultChart Method (PowerPoint)

office 365 dev account|Last Updated: 6/12/2017
1 Contributor

Specifies the name of the chart template that Microsoft Word uses when it creates new charts.


expression. SetDefaultChart( Name )

expression A variable that represents a Chart object.


NameRequired/OptionalData TypeDescription
NameRequiredVariantSpecifies the name of the default chart template that Word uses when it creates new charts. This name can be set to either the name of a user-defined chart template in the gallery or a special XlChartGallery constant, xlBuiltIn, to specify a built-in chart template.


Note Although the following code applies to Microsoft Word, you can readily modify it to apply to PowerPoint.

The following example sets the default chart template to a custom chart template named "Monthly Sales."

With ActiveDocument.InlineShapes(1)

    If .HasChart Then

        .Chart.SetDefaultChart Name:="Monthly Sales"

    End If

End With

See also


Chart Object

© 2018 Microsoft