API Reference
Export-OfficeHtmlImage
Exports an HTML render surface as PNG or SVG with structured diagnostics.
Remarks
Exports an HTML render surface as PNG or SVG with structured diagnostics.
Examples
Render an HTML file to PNG.
PS>
Export-OfficeHtmlImage -Path .\Report.html -OutputPath .\Report.png
Uses the dependency-free OfficeIMO HTML renderer. Add -PassThru to receive the structured export result.
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-OfficeHtmlImage [-DocumentOptions <HtmlConversionDocumentOptions>] [-Format <Png|Svg|Jpeg|Tiff|Webp>] -OutputPath <String> [-PageIndex <Int32>] [-PassThru] -Path <String> [-RenderOptions <HtmlRenderOptions>] [<CommonParameters>]#PathParameters
- DocumentOptions HtmlConversionDocumentOptions
- Optional HTML parsing and trust settings for path or markup input.
- Format OfficeImageExportFormat
- Output image format.
- Possible values:
Png,Svg,Jpeg,Tiff,Webp - OutputPath String
- Destination PNG, JPEG, TIFF, SVG, or WebP path.
- PageIndex Int32
- Zero-based rendered page index.
- PassThru SwitchParameter
- Emit the structured image export result.
- Path String
- Path to an HTML file.
- RenderOptions HtmlRenderOptions
- Optional size, pagination, resource, and rendering settings.
Outputs
OfficeIMO.Drawing.OfficeImageExportResult
Export-OfficeHtmlImage [-DocumentOptions <HtmlConversionDocumentOptions>] [-Format <Png|Svg|Jpeg|Tiff|Webp>] -Html <String> -OutputPath <String> [-PageIndex <Int32>] [-PassThru] [-RenderOptions <HtmlRenderOptions>] [<CommonParameters>]#HtmlParameters
- DocumentOptions HtmlConversionDocumentOptions
- Optional HTML parsing and trust settings for path or markup input.
- Format OfficeImageExportFormat
- Output image format.
- Possible values:
Png,Svg,Jpeg,Tiff,Webp - Html String
- HTML markup to render.
- OutputPath String
- Destination PNG, JPEG, TIFF, SVG, or WebP path.
- PageIndex Int32
- Zero-based rendered page index.
- PassThru SwitchParameter
- Emit the structured image export result.
- RenderOptions HtmlRenderOptions
- Optional size, pagination, resource, and rendering settings.
Outputs
OfficeIMO.Drawing.OfficeImageExportResult
Export-OfficeHtmlImage -Document <HtmlConversionDocument> [-DocumentOptions <HtmlConversionDocumentOptions>] [-Format <Png|Svg|Jpeg|Tiff|Webp>] -OutputPath <String> [-PageIndex <Int32>] [-PassThru] [-RenderOptions <HtmlRenderOptions>] [<CommonParameters>]#DocumentParameters
- Document HtmlConversionDocument
- Shared HTML conversion document.
- DocumentOptions HtmlConversionDocumentOptions
- Optional HTML parsing and trust settings for path or markup input.
- Format OfficeImageExportFormat
- Output image format.
- Possible values:
Png,Svg,Jpeg,Tiff,Webp - OutputPath String
- Destination PNG, JPEG, TIFF, SVG, or WebP path.
- PageIndex Int32
- Zero-based rendered page index.
- PassThru SwitchParameter
- Emit the structured image export result.
- RenderOptions HtmlRenderOptions
- Optional size, pagination, resource, and rendering settings.
Outputs
OfficeIMO.Drawing.OfficeImageExportResult