HtmlToPdfStaticRenderHtmlAsPdf Method (String, Uri, PdfPrintOptions, String)

Static version of the RenderHtmlAsPdf(String, Uri, String) function. Renders any Html strings into a PDF document.

Namespace:  IronPdf
Assembly:  IronPdf (in IronPdf.dll) Version: 2020.10.3
public static PdfDocument StaticRenderHtmlAsPdf(
	string Html,
	Uri BaseUrl = null,
	PdfPrintOptions PrintOptions = null,
	string Proxy = null


Type: SystemString
Html to be turned into a PDF.
BaseUrl (Optional)
Type: SystemUri
Setting the BaseURL property gives the Html a relative for content links such as hyper-links, images, CSS and JavaScript files.
PrintOptions (Optional)
Type: IronPdfPdfPrintOptions
Instance of PdfPrintOptions. Optional print options and settings.
Proxy (Optional)
Type: SystemString
Specifies an Http proxy server. Use the pattern: http(s)://user-name:password@host:port/

Return Value

Type: PdfDocument
A PdfDocument
See Also
Install with Nuget