API Reference
Cmdlet
Compare-OfficeWordDocument
Compares two Word documents and optionally writes a tracked-change redline.
Remarks
Compares two Word documents and optionally writes a tracked-change redline.
Examples
Create a structured comparison and redline.
PS>
$result = Compare-OfficeWordDocument -ReferencePath .\Before.docx -DifferencePath .\After.docx -RedlinePath .\Redline.docx
Returns deterministic findings and saves a Word document containing revision marks.
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
Compare-OfficeWordDocument -DifferencePath <String> [-Options <WordComparisonOptions>] [-RedlinePath <String>] -ReferencePath <String> [<CommonParameters>]#Parameter set:
All Parameter SetsParameters
- DifferencePath String
- Path to the modified Word document.
- Options WordComparisonOptions
- Optional structural comparison switches.
- RedlinePath String
- Optional path for a tracked-change redline document.
- ReferencePath String
- Path to the original Word document.
Outputs
OfficeIMO.Word.WordComparisonResult