CreateSummary Method

         Example         Applies To

Creates a new worksheet that contains a summary report for the scenarios on the specified worksheet.

Syntax

expression.CreateSummary(ReportType, ResultCells)

expression   Required. An expression that returns a Scenarios collection.

ReportType   Optional Variant. The report type. Can be one of the following XlSummaryReportType constants: xlStandardSummary or xlSummaryPivotTable.The default value is xlStandardSummary.

ResultCells   Optional Variant. A Range object that represents the result cells on the specified worksheet. Normally, this range refers to one or more cells containing the formulas that depend on the changing cell values for your model — that is, the cells that show the results of a particular scenario. If this argument is omitted, there are no result cells included in the report.