HTML to PDF
  • 04 Mar 2025
  • 1 Minute to read
  • Dark
    Light

HTML to PDF

  • Dark
    Light

Article summary

 

Step Details

Introduced in Version

---

Last Modified in Version

9.8

Location

Data > PDF


The HTML to PDF step converts a text or HTML input file into PDF format. It is used with the Create File step to create the PDF file. One use case for this step may include converting a patient's old text-formatted medical record into a PDF.

Known Issue for All Versions Before 8.21:

Decisions uses the Aspose library to convert HTML to PDF format. Aspose library does not convert the hyperlinks within the HTML file. Thus, after conversion, the hyperlinks will not work. One solution is to use the ‘HTML to Word Document’ step first and then use the ‘Convert Word to PDF’ step.


Properties

Configuration

  
PropertyDescriptionData Type

Get HTML From File

Changes the HTML input data type from String to FileData.

Boolean

Set Page Dimensions

Includes additional inputs to further customize the PDF being created. Page Height, Page Width, Page Margins. Page Dimensions are set in inches.


Changing Page OrientationBy default, the page orientation is set to portrait (8.89 × 13.00 in.). To change the page orientation from portrait to landscape, users can enable the "Set Page Dimensions" and set the Page Height and Page Width to the required lengths in inches.

Boolean

Use Custom Page Numbers

This will replace the "Include Page Numbers" input with "Custom Page Numbers" input.

Boolean

Allow Links

Available in v8.21+, when this box is checked, the Flow will use aspose.words instead of aspose.pdf for conversion.

Boolean
Contains Rich Text ImagesAvailable in v9.8+. Use this so that resized images will appear properly on the PDF file.Boolean

Inputs

PropertyDescriptionData Type
HTML

HTML file to convert to PDF.

String/FileData

Include Page Numbers or Custom Page Numbers

Determine whether Page Numbers are included and include a dynamic way of displaying the Page Numbers.

Boolean/String

Page Number Alignment

Determines whether the Page Number will be Left, Right, or Center.

HorizontalPlacement

PDF File Name

Full file name of the PDF file, include .pdf

String

Outputs

PropertyDescription.Data Type
PDF FileConverted PDFFileData
Error MessageThe text of the error message.String


Allow Links Feature (available in v8.21+)



Step Changes

DescriptionVersionRelease DateDeveloper Task

Added Allow Links check box to prevent links within PDF files created by the HTML to PDF Step from working.

8.21

September 2024[DT-041223]
A new property has been added to the HTML to PDF step named "Contains Rich Text Images".
9.8March 2025[DT-043824]

Related Information

Example Labs:
Saving Sent Emails as PDFs
Converting Forms to PDFs for Email
Combining PDFs Using a Custom Group Action 
Forum Posts:
Html To Pdf
Conversion Error For HTMLtoPDF Step
Set Page Dimensions Checkbox In Html To PDF Step


Was this article helpful?