Cmdlet
Export-OfficeDocumentImage
Renders native pages, slides, sheets, ranges or charts and saves each image atomically.
Syntax
Export-OfficeDocumentImage
[-BackgroundColor <OfficeColor>]
[-Chart <String>]
[-Dpi <Double>]
[-Format <OfficeImageFormat>]
[-NoClobber]
[-Options <Object[]>]
[-OutputDirectory] <String>
[-Page <OfficePageRange>]
[-Password <SecureString>]
[-Path] <String[]>
[-Range <String>]
[-Scale <Double>]
[-Sheet <OfficeSheetSelector[]>]
[-ThrottleLimit <Int32>]
[<CommonParameters>]#Parameter set:
PathExport-OfficeDocumentImage
[-BackgroundColor <OfficeColor>]
[-Chart <String>]
[-Dpi <Double>]
[-Format <OfficeImageFormat>]
[-NoClobber]
[-Options <Object[]>]
[-OutputPath] <String>
[-Page <OfficePageRange>]
[-Password <SecureString>]
[-Path] <String[]>
[-Range <String>]
[-Scale <Double>]
[-Sheet <OfficeSheetSelector[]>]
[<CommonParameters>]#Parameter set:
PathFileExport-OfficeDocumentImage
[-BackgroundColor <OfficeColor>]
[-Chart <String>]
[-Dpi <Double>]
[-Format <OfficeImageFormat>]
-LiteralPath <String[]>
[-NoClobber]
[-Options <Object[]>]
[-OutputDirectory] <String>
[-Page <OfficePageRange>]
[-Password <SecureString>]
[-Range <String>]
[-Scale <Double>]
[-Sheet <OfficeSheetSelector[]>]
[-ThrottleLimit <Int32>]
[<CommonParameters>]#Parameter set:
LiteralPathExport-OfficeDocumentImage
[-BackgroundColor <OfficeColor>]
[-Chart <String>]
[-Dpi <Double>]
[-Format <OfficeImageFormat>]
-LiteralPath <String[]>
[-NoClobber]
[-Options <Object[]>]
[-OutputPath] <String>
[-Page <OfficePageRange>]
[-Password <SecureString>]
[-Range <String>]
[-Scale <Double>]
[-Sheet <OfficeSheetSelector[]>]
[<CommonParameters>]#Parameter set:
LiteralPathFileExport-OfficeDocumentImage
[-BackgroundColor <OfficeColor>]
[-Chart <String>]
[-Document] <Object>
[-Dpi <Double>]
[-Format <OfficeImageFormat>]
[-NoClobber]
[-Options <Object[]>]
[-OutputDirectory] <String>
[-Page <OfficePageRange>]
[-Password <SecureString>]
[-Range <String>]
[-Scale <Double>]
[-Sheet <OfficeSheetSelector[]>]
[<CommonParameters>]#Parameter set:
DocumentExport-OfficeDocumentImage
[-BackgroundColor <OfficeColor>]
[-Chart <String>]
[-Document] <Object>
[-Dpi <Double>]
[-Format <OfficeImageFormat>]
[-NoClobber]
[-Options <Object[]>]
[-OutputPath] <String>
[-Page <OfficePageRange>]
[-Password <SecureString>]
[-Range <String>]
[-Scale <Double>]
[-Sheet <OfficeSheetSelector[]>]
[<CommonParameters>]#Parameter set:
DocumentFileExport-OfficeDocumentImage
[-BackgroundColor <OfficeColor>]
[-Chart <String>]
[-Dpi <Double>]
[-Format <OfficeImageFormat>]
-From <String>
[-NoClobber]
[-Options <Object[]>]
[-OutputDirectory] <String>
[-Page <OfficePageRange>]
[-Password <SecureString>]
[-Range <String>]
[-Scale <Double>]
[-Sheet <OfficeSheetSelector[]>]
[-Text] <String>
[<CommonParameters>]#Parameter set:
TextExport-OfficeDocumentImage
[-BackgroundColor <OfficeColor>]
[-Chart <String>]
[-Dpi <Double>]
[-Format <OfficeImageFormat>]
-From <String>
[-NoClobber]
[-Options <Object[]>]
[-OutputPath] <String>
[-Page <OfficePageRange>]
[-Password <SecureString>]
[-Range <String>]
[-Scale <Double>]
[-Sheet <OfficeSheetSelector[]>]
[-Text] <String>
[<CommonParameters>]#Parameter set:
TextFileExamples
Export selected slides.
Export-OfficeDocumentImage -Path ./review.pptx -Page 1-3 -Format Svg -OutputDirectory ./slidesExport exactly one worksheet range.
Export-OfficeDocumentImage -LiteralPath './budget[final].xlsx' -Sheet Dashboard -Range A1:H30 -OutputPath ./dashboard.png -NoClobberParameters
- -BackgroundColor OfficeColor
- Image background, including Transparent.
- -Chart String
- Chart name within the selected Excel sheets. Cannot be combined with Range.
- -Dpi Double
- Target image resolution in dots per inch; omitted values retain native options.
- -Format OfficeImageFormat
- Output image encoding. File destinations infer it when omitted.
- Possible values:
Unknown,Png,Jpeg,Gif,Bmp,Tiff,Svg,Emf,Wmf,Icon,Pcx,Webp,Jpeg2000,Jpeg2000Codestream,Avif,JpegXr,PortableMap,Tga,Heic - -NoClobber SwitchParameter
- Refuse to replace an existing destination image.
- -Options Object[]
- Native image/load options or hashtables, routed to the selected source formats.
- -OutputDirectory String
- Destination folder for the selected image batch.
- -Page OfficePageRange
- One-based caller-ordered pages, slides or diagram pages; defaults to all.
- -Password SecureString
- Password used only when opening encrypted source files.
- -Path String[]
- Input paths, with FileSystem wildcard expansion.
- -Range String
- A1 range within the selected Excel sheets.
- -Scale Double
- Image scale; omitted values retain native options.
- -Sheet OfficeSheetSelector[]
- Excel worksheets selected by name, one-based position or native sheet object.
- -ThrottleLimit Int32
- Maximum number of input files processed concurrently.
- -OutputPath String
- Exact single-image destination; its extension selects the default encoding.
- -LiteralPath String[]
- Literal paths; accepts FileInfo, PSPath and FullName properties.
- -Document Object
- Caller-owned native document, including current unsaved content.
- -From String
- Markup source format; use Html.
- -Text String
- Literal HTML markup.
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.