Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Cmdlet

Get-OfficeExcelConditionalFormat

Module
PSWriteOffice
Inputs
OfficeIMO.Excel.ExcelDocument System.String[]
Outputs
OfficeIMO.Excel.ExcelConditionalFormattingInfo

Gets native conditional formatting snapshots, with worksheet and source-path metadata.

Syntax

Get-OfficeExcelConditionalFormat
[-Document <ExcelDocument>]
[-Header <String>]
[-HeaderRow <Int32>]
[-IncludeHeader]
[-Range <String>]
[-Sheet <OfficeSheetSelector[]>]
[-Table <String>]
[<CommonParameters>]
#
Parameter set: Document
Get-OfficeExcelConditionalFormat
[-Header <String>]
[-HeaderRow <Int32>]
[-IncludeHeader]
[-Path] <String[]>
[-Range <String>]
[-Sheet <OfficeSheetSelector[]>]
[-Table <String>]
[<CommonParameters>]
#
Parameter set: Path
Get-OfficeExcelConditionalFormat
[-Header <String>]
[-HeaderRow <Int32>]
[-IncludeHeader]
-LiteralPath <String[]>
[-Range <String>]
[-Sheet <OfficeSheetSelector[]>]
[-Table <String>]
[<CommonParameters>]
#
Parameter set: LiteralPath

Examples

Inspect rules for a named table column.

Get-OfficeExcelConditionalFormat -Path .\Report.xlsx -Sheet Data -Table Sales -Header Status

Parameters

-Document ExcelDocument optionalpipeline: True (ByValue)sets: Document
Caller-owned workbook; omission uses the enclosing Excel content block.
-Header String optional
Header or table column name used to resolve the range filter.
-HeaderRow Int32 optional
Worksheet header row; zero uses the first row of the used range.
-IncludeHeader SwitchParameter optional
Include the header cell when resolving a named column.
-Range String optional
A1 range filter; Header takes precedence when both are supplied.
-Sheet OfficeSheetSelector[] optional
Worksheet names, wildcard patterns, one-based positions or native worksheet objects.
-Table String optional
Table name for header-based range resolution.
-Path String[] requiredposition: 0pipeline: True (ByValue)sets: Path
Workbook paths, including filesystem wildcard patterns.
-LiteralPath String[] requiredpipeline: True (ByPropertyName)aliases: FullName, PSPathsets: LiteralPath
Literal workbook paths. FileInfo.FullName and provider PSPath bind here.

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.