List-SLWorkSheet


Synopsis

List all worksheets contained in a workbook.

Syntax

Description

List all worksheets contained in a workbook.
This is intended to quickly provide a way for the user to determine what worksheets are contained in a workbook
Note: The workbook instance is not passed through.

Parameters

-WorkBookInstance

Instance of an excel document that can be used for editing.

Required? True
Position? 0
Default value  
Accept pipeline input? true (ByValue)
Accept wildcard characters? False

-Filter

Simple Filter that supports regex matches.

Required? False
Position? 2
Default value  
Accept pipeline input? false
Accept wildcard characters? False

-Path

The path to the excel document.

Required? True
Position? 1
Default value  
Accept pipeline input? false
Accept wildcard characters? False

This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).

Inputs

String[]

Outputs

SpreadsheetLight.SLDocument

Notes

Examples

Example 1

Lists all worksheets contained in the document named &;39;MyFirstDoc&;39;

Example 2

Get-SLDocument is used to get an instance of the document named &;39;MyFirstDoc&;39; which is then piped to List-SLWorkSheet

Example 3

List all worksheets that match either a or b.

Example 4

List all worksheets that DONT match either a or b.

Example 5

List all worksheets that have the word &;39;sheet&;39;.

Related links