CreateSheet method: PSSpreadsheet class
Syntax
CreateSheet(sheetname)
Description
Use the CreateSheet method to create and name a new spreadsheet within the open Excel workbook.
Parameters
| Parameter | Description |
|---|---|
|
sheetname |
Specifies a String value representing the name of the new spreadsheet. |
Returns
(Optional) A Boolean value: True if the method completes successfully, False otherwise.
Example
The following example sets Addresses as the name of the new spreadsheet.
&sheetname = "Addresses";
&ssObject.CreateSheet(&sheetname);