SetSheetActivate method: PSSpreadsheet class

Syntax

SetSheetActivate(sheetnum)

Description

Use the SetSheetActivate method to activate the specified sheet in the Excel workbook.

Parameters

Parameter Description

sheetnum

Specifies the number of sheet to be activated in the Excel workbook.

Returns

(Optional) A Boolean value: True if the method completes successfully, False otherwise.

Example

The following example activates sheet 2 within the Excel workbook.

&sheetnum = 2;
&ssObject.SetSheetActivate(&sheetnum);