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

Chart.Copy Method (Project)

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

Copies a chart.

Syntax

expression. Copy

expression A variable that represents a Chart object.

Return value

Variant

Example

The following example copies the chart and then pastes the chart as a picture on the active report.

Sub CopyAndPasteChart()
    Dim chartShape As Shape
    Dim reportName As String
    Dim duplicateChart As Chart

    reportName = "Simple scalar chart"
    Set chartShape = ActiveProject.Reports(reportName).Shapes(1)

    chartShape.Chart.Copy
    Application.PasteAsPicture
End Sub

See also

Other resources

Chart ObjectCopyPicture Method

© 2018 Microsoft