API Reference
Cmdlet
Export-OfficeExcelRangeImage
Exports one worksheet range as an image file.
Remarks
Exports one worksheet range as an image file.
Examples
Export a report range for use in an email.
PS>
Export-OfficeExcelRangeImage -Path .\Report.xlsx -WorksheetName Summary -Range A1:H20 -OutputPath .\summary.png
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
Export-OfficeExcelRangeImage [-Force] [-Format <Png|Svg|Jpeg|Tiff|Webp>] [-Options <ExcelImageExportOptions>] [-OutputPath <String>] -Path <String> -Range <String> -WorksheetName <String> [<CommonParameters>]#Parameter set:
PathParameters
- Force SwitchParameter
- Replace an existing destination file.
- Format OfficeImageExportFormat
- Output image format.
- Possible values:
Png,Svg,Jpeg,Tiff,Webp - Options ExcelImageExportOptions
- Optional rendering, size, font, and diagnostic policy settings.
- OutputPath String
- Optional destination image file. When omitted, returns the in-memory image result only.
- Path String
- Path to the workbook.
- Range String
- A1 range address to export.
- WorksheetName String
- Name of the worksheet containing the range.
Outputs
OfficeIMO.Drawing.OfficeImageExportResult
Export-OfficeExcelRangeImage -Document <ExcelDocument> [-Force] [-Format <Png|Svg|Jpeg|Tiff|Webp>] [-Options <ExcelImageExportOptions>] [-OutputPath <String>] -Range <String> -WorksheetName <String> [<CommonParameters>]#Parameter set:
DocumentParameters
- Document ExcelDocument
- Open workbook instance.
- Force SwitchParameter
- Replace an existing destination file.
- Format OfficeImageExportFormat
- Output image format.
- Possible values:
Png,Svg,Jpeg,Tiff,Webp - Options ExcelImageExportOptions
- Optional rendering, size, font, and diagnostic policy settings.
- OutputPath String
- Optional destination image file. When omitted, returns the in-memory image result only.
- Range String
- A1 range address to export.
- WorksheetName String
- Name of the worksheet containing the range.
Outputs
OfficeIMO.Drawing.OfficeImageExportResult