API Reference
Command
Set-OfficeExcelFreeze
Freezes panes on the current worksheet.
Remarks
Freezes panes on the current worksheet.
Examples
Freeze the top row.
PS>ExcelSheet 'Data' { Set-OfficeExcelFreeze -TopRows 1 }
Freezes the first row.
Freeze the top row and first column.
PS>ExcelSheet 'Data' { Set-OfficeExcelFreeze -TopRows 1 -LeftColumns 1 }
Freezes row 1 and column A.
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.
Syntax
Set-OfficeExcelFreeze [-LeftColumns <Int32>] [-TopRows <Int32>] [<CommonParameters>]#Parameter set:
ContextParameters
- LeftColumns Int32
- Number of columns to freeze from the left.
- TopRows Int32
- Number of rows to freeze from the top.
Outputs
System.Object
Set-OfficeExcelFreeze -Document <ExcelDocument> [-LeftColumns <Int32>] [-Sheet <String>] [-SheetIndex <Nullable`1>] [-TopRows <Int32>] [<CommonParameters>]#Parameter set:
DocumentParameters
- Document ExcelDocument
- Workbook to operate on outside the DSL context.
- LeftColumns Int32
- Number of columns to freeze from the left.
- Sheet String
- Worksheet name when using Document.
- SheetIndex Nullable`1
- Worksheet index (0-based) when using Document.
- TopRows Int32
- Number of rows to freeze from the top.
Outputs
System.Object