Export (0) Print
Expand All
Expand Minimize

Workbook.Charts Property

Gets a Microsoft.Office.Interop.Excel.Sheets collection that represents all the chart sheets in the workbook.

Namespace: Microsoft.Office.Tools.Excel
Assembly: Microsoft.Office.Tools.Excel (in microsoft.office.tools.excel.dll)

public virtual Sheets Charts { get; }

Property Value

A Microsoft.Office.Interop.Excel.Sheets collection that represents all the chart sheets in the workbook.

The following code example uses the Charts property to generate a print preview of all the chart sheets in the current workbook.

private void PreviewCharts()
{
    if (this.Charts.Count > 0)
    {
        this.Charts.PrintPreview(false);
    }
}

Show:
© 2014 Microsoft