Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Cmdlet

Save-OfficeOpenDocument

Module
PSWriteOffice
Inputs
OfficeIMO.OpenDocument.OdfDocument
Outputs
OfficeIMO.OpenDocument.OdfSaveResult

Saves a native OpenDocument model with entry-level preservation diagnostics.

Syntax

Save-OfficeOpenDocument
-Document <OdfDocument>
[-FailOnLoss]
[-Options <OdfSaveOptions>]
[-PassThru]
[[-Path] <String>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
#
Parameter set: Document

Examples

Save a live document to its associated destination.

$document = New-OfficeOpenDocument -Path ./Proposal.odt
Save-OfficeOpenDocument -Document $document

Parameters

-Document OdfDocument requiredpipeline: True (ByValue)
OpenDocument model to save.
-FailOnLoss SwitchParameter optional
Throw when source entries cannot be preserved losslessly.
-Options OdfSaveOptions optional
Optional package save and preservation settings.
-PassThru SwitchParameter optional
Emit the save result, including preservation diagnostics.
-Path String optionalposition: 0
Destination path; defaults to the document's associated save path.
-WhatIf SwitchParameter optional
Shows what would happen if the command runs.
-Confirm SwitchParameter optional
Prompts for confirmation before running the command.

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.