Move-SLWorkSheet


Synopsis

Moves a worksheet.

Syntax

Description

Moves a worksheet.Only one worksheet can be moved at a time.

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

-WorkSheetName

Name of the Worksheet to be Moved.

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

-Position

Position index. Use 1 for 1st position, 2 for 2nd position and so on.
If there were 10 worksheets in a document and you specify the value of the position parameter as 20 for sheet1 the
worksheet will then be moved to the last position in the document.

Required? True
Position? 2
Default value  
Accept pipeline input? true (ByPropertyName)
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

UInt

SpreadsheetLight.SLDocument

Outputs

SpreadsheetLight.SLDocument

Notes

Examples

Example 1

Sheet1 is moved from its current position to position 100, assuming of course there are 100 worksheets in the document.
If there were 10 worksheets in a document and you specify the value of the position parameter as 20 for sheet1 the
worksheet will then be moved to the last position in the document.

Related links