mirror of
https://github.com/dfinke/ImportExcel.git
synced 2025-12-06 00:23:20 +00:00
@@ -3,27 +3,28 @@ function New-ConditionalText {
|
||||
[Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseShouldProcessForStateChangingFunctions', '',Justification='Does not change system State')]
|
||||
param(
|
||||
#[Parameter(Mandatory=$true)]
|
||||
[Alias("ConditionValue")]
|
||||
[Alias('ConditionValue')]
|
||||
$Text,
|
||||
[Alias("ForeGroundColor")]
|
||||
[Alias('ForeGroundColor')]
|
||||
$ConditionalTextColor=[System.Drawing.Color]::DarkRed,
|
||||
$BackgroundColor=[System.Drawing.Color]::LightPink,
|
||||
[String]$Range,
|
||||
[OfficeOpenXml.Style.ExcelFillStyle]$PatternType=[OfficeOpenXml.Style.ExcelFillStyle]::Solid,
|
||||
[ValidateSet(
|
||||
"LessThan", "LessThanOrEqual", "GreaterThan", "GreaterThanOrEqual",
|
||||
"Equal", "NotEqual",
|
||||
"Top", "TopPercent", "Bottom", "BottomPercent",
|
||||
"ContainsText", "NotContainsText", "BeginsWith", "EndsWith",
|
||||
"ContainsBlanks", "NotContainsBlanks", "ContainsErrors", "NotContainsErrors",
|
||||
"DuplicateValues", "UniqueValues",
|
||||
"Tomorrow", "Today", "Yesterday", "Last7Days",
|
||||
"NextWeek", "ThisWeek", "LastWeek",
|
||||
"NextMonth", "ThisMonth", "LastMonth",
|
||||
"AboveAverage", "AboveOrEqualAverage", "BelowAverage", "BelowOrEqualAverage"
|
||||
'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual',
|
||||
'Equal', 'NotEqual',
|
||||
'Top', 'TopPercent', 'Bottom', 'BottomPercent',
|
||||
'ContainsText', 'NotContainsText', 'BeginsWith', 'EndsWith',
|
||||
'ContainsBlanks', 'NotContainsBlanks', 'ContainsErrors', 'NotContainsErrors',
|
||||
'DuplicateValues', 'UniqueValues',
|
||||
'Tomorrow', 'Today', 'Yesterday', 'Last7Days',
|
||||
'NextWeek', 'ThisWeek', 'LastWeek',
|
||||
'NextMonth', 'ThisMonth', 'LastMonth',
|
||||
'AboveAverage', 'AboveOrEqualAverage', 'BelowAverage', 'BelowOrEqualAverage',
|
||||
'Expression'
|
||||
)]
|
||||
[Alias("RuleType")]
|
||||
$ConditionalType="ContainsText"
|
||||
[Alias('RuleType')]
|
||||
$ConditionalType='ContainsText'
|
||||
)
|
||||
|
||||
$obj = [PSCustomObject]@{
|
||||
|
||||
Reference in New Issue
Block a user