mirror of
https://github.com/dfinke/ImportExcel.git
synced 2025-12-06 00:23:20 +00:00
Update and rename ConditionalFormattingUnmatchColumns.ps1 to ConditionalFormattingUnmatchColumns-Sol1.ps1
Minor update and change the filename as Solution 1
This commit is contained in:
@@ -19,8 +19,8 @@ Remove-Item $xlfile -ErrorAction SilentlyContinue
|
||||
|
||||
$file = $data | Export-Excel $xlfile -AutoSize -PassThru
|
||||
|
||||
$cfi1 = Add-ConditionalFormatting -Worksheet $file.sheet1 -Range '$D$2:$D$1048576' -ConditionValue '=NOT(EXACT($A2,$D2))' -RuleType Expression -ForegroundColor Red
|
||||
$cfi2 = Add-ConditionalFormatting -Worksheet $file.sheet1 -Range '$E$2:$E$1048576' -ConditionValue '=NOT(EXACT($B2,$E2))' -RuleType Expression -ForegroundColor Red
|
||||
$cfi3 = Add-ConditionalFormatting -Worksheet $file.sheet1 -Range '$F$2:$F$1048576' -ConditionValue '=NOT(EXACT($C2,$F2))' -RuleType Expression -ForegroundColor Red
|
||||
Add-ConditionalFormatting -Worksheet $file.sheet1 -Range '$D$2:$D$1048576' -ConditionValue '=NOT(EXACT($A2,$D2))' -RuleType Expression -ForegroundColor Red
|
||||
Add-ConditionalFormatting -Worksheet $file.sheet1 -Range '$E$2:$E$1048576' -ConditionValue '=NOT(EXACT($B2,$E2))' -RuleType Expression -ForegroundColor Red
|
||||
Add-ConditionalFormatting -Worksheet $file.sheet1 -Range '$F$2:$F$1048576' -ConditionValue '=NOT(EXACT($C2,$F2))' -RuleType Expression -ForegroundColor Red
|
||||
|
||||
Close-ExcelPackage $file -Show
|
||||
Reference in New Issue
Block a user