Cmdlet
Get-OfficeDocumentAsset
Reads or materializes embedded assets discovered by OfficeIMO.Reader from a supported document.
Syntax
Get-OfficeDocumentAsset [-ExcelA1Range <String>] [-ExcelChunkRows <Int32>] [-ExcelSheetName <String>] [-ExcludePowerPointNotes] [-ExcludeWordFootnotes] [-Extension <String[]>] [-Kind <String[]>] [-MaxChars <Int32>] [-MaxInputBytes <Int64>] [-MaxTableRows <Int32>] [-MediaType <String[]>] [-NoExcelHeaders] [-NoHashes] [-NoMarkdownHeadingChunks] [-NoOverwrite] [-OpenXmlMaxCharactersInPart <Int64>] [-OutputDirectory <String>] [-Path] <String> [-Reader <OfficeDocumentReader>] [-ValidatePayloadHash] [<CommonParameters>]#Parameter set:
All Parameter SetsExamples
List embedded assets in a document.
Get-OfficeDocumentAsset -Path .\Report.docx |
Select-Object Id, Kind, MediaType, FileName, LengthBytesReads the normalized asset metadata emitted by the shared Reader envelope.
Export document images to a folder.
Get-OfficeDocumentAsset -Path .\Deck.pptx -OutputDirectory .\reader-assets -Kind image -ValidatePayloadHashWrites materializable image payloads to deterministic filenames and returns materialization results.
Parameters
- -ExcelA1Range String
- Optional Excel A1 range to read.
- -ExcelChunkRows Int32
- Excel rows per emitted worksheet chunk.
- -ExcelSheetName String
- Optional Excel sheet name to read.
- -ExcludePowerPointNotes SwitchParameter
- Exclude PowerPoint speaker notes.
- -ExcludeWordFootnotes SwitchParameter
- Exclude Word footnotes.
- -Extension String[]
- Only include assets with one of these file extensions.
- -Kind String[]
- Only include assets with one of these normalized kinds, such as image or preview.
- -MaxChars Int32
- Maximum emitted chunk characters.
- -MaxInputBytes Int64
- Maximum input size in bytes.
- -MaxTableRows Int32
- Maximum table rows per emitted table.
- -MediaType String[]
- Only include assets with one of these media types.
- -NoExcelHeaders SwitchParameter
- Treat the first Excel row as data instead of headers.
- -NoHashes SwitchParameter
- Disable source and chunk hash computation.
- -NoMarkdownHeadingChunks SwitchParameter
- Do not split Markdown by headings.
- -NoOverwrite SwitchParameter
- Do not overwrite existing payload files when -OutputDirectory is used.
- -OpenXmlMaxCharactersInPart Int64
- OpenXML maximum characters per part.
- -OutputDirectory String
- Optional directory where materializable asset payloads should be written.
- -Path String
- File path to read.
- -Reader OfficeDocumentReader
- Optional immutable OfficeIMO reader with caller-configured handlers and processors.
- -ValidatePayloadHash SwitchParameter
- Validate payload hashes before writing assets when hash metadata is present.
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.