API Reference

Cmdlet

Get-OfficeDocumentAsset

Aliases: Export-OfficeDocumentAsset, Read-OfficeDocumentAsset
Namespace PSWriteOffice
Aliases
Export-OfficeDocumentAsset Read-OfficeDocumentAsset
Inputs
System.String
Outputs
OfficeIMO.Reader.OfficeDocumentAsset OfficeIMO.Reader.OfficeDocumentMaterializedAsset

Reads or materializes embedded assets discovered by OfficeIMO.Reader from a supported document.

Remarks

Reads or materializes embedded assets discovered by OfficeIMO.Reader from a supported document.

Examples

Authored help example

List embedded assets in a document.

PS>


Get-OfficeDocumentAsset -Path .\Report.docx |
                Select-Object Id, Kind, MediaType, FileName, LengthBytes
        

Reads the normalized asset metadata emitted by the shared Reader envelope.

Export document images to a folder.

PS>


Get-OfficeDocumentAsset -Path .\Deck.pptx -OutputDirectory .\reader-assets -Kind image -ValidatePayloadHash
        

Writes materializable image payloads to deterministic filenames and returns materialization results.

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

Get-OfficeDocumentAsset [-ExcelA1Range <String>] [-ExcelChunkRows <Nullable`1>] [-ExcelSheetName <String>] [-ExcludePowerPointNotes] [-ExcludeWordFootnotes] [-Extension <String[]>] [-Kind <String[]>] [-MaxChars <Nullable`1>] [-MaxInputBytes <Nullable`1>] [-MaxTableRows <Nullable`1>] [-MediaType <String[]>] [-NoExcelHeaders] [-NoHashes] [-NoMarkdownHeadingChunks] [-NoOverwrite] [-OpenXmlMaxCharactersInPart <Nullable`1>] [-OutputDirectory <String>] -Path <String> [-Reader <OfficeDocumentReader>] [-ValidatePayloadHash] [<CommonParameters>]
#
Parameter set: All Parameter Sets

Parameters

ExcelA1Range String optionalposition: namedpipeline: False
Optional Excel A1 range to read.
ExcelChunkRows Nullable`1 optionalposition: namedpipeline: False
Excel rows per emitted worksheet chunk.
ExcelSheetName String optionalposition: namedpipeline: False
Optional Excel sheet name to read.
ExcludePowerPointNotes SwitchParameter optionalposition: namedpipeline: False
Exclude PowerPoint speaker notes.
ExcludeWordFootnotes SwitchParameter optionalposition: namedpipeline: False
Exclude Word footnotes.
Extension String[] optionalposition: namedpipeline: False
Only include assets with one of these file extensions.
Kind String[] optionalposition: namedpipeline: False
Only include assets with one of these normalized kinds, such as image or preview.
MaxChars Nullable`1 optionalposition: namedpipeline: False
Maximum emitted chunk characters.
MaxInputBytes Nullable`1 optionalposition: namedpipeline: False
Maximum input size in bytes.
MaxTableRows Nullable`1 optionalposition: namedpipeline: False
Maximum table rows per emitted table.
MediaType String[] optionalposition: namedpipeline: False
Only include assets with one of these media types.
NoExcelHeaders SwitchParameter optionalposition: namedpipeline: False
Treat the first Excel row as data instead of headers.
NoHashes SwitchParameter optionalposition: namedpipeline: False
Disable source and chunk hash computation.
NoMarkdownHeadingChunks SwitchParameter optionalposition: namedpipeline: False
Do not split Markdown by headings.
NoOverwrite SwitchParameter optionalposition: namedpipeline: False
Do not overwrite existing payload files when -OutputDirectory is used.
OpenXmlMaxCharactersInPart Nullable`1 optionalposition: namedpipeline: False
OpenXML maximum characters per part.
OutputDirectory String optionalposition: namedpipeline: False
Optional directory where materializable asset payloads should be written.
Path String requiredposition: 0pipeline: True (ByValue)aliases: FilePath
File path to read.
Reader OfficeDocumentReader optionalposition: namedpipeline: False
ValidatePayloadHash SwitchParameter optionalposition: namedpipeline: False
Validate payload hashes before writing assets when hash metadata is present.

Outputs

OfficeIMO.Reader.OfficeDocumentAsset OfficeIMO.Reader.OfficeDocumentMaterializedAsset