ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

New WINDEV and WEBDEV 28 feature!
Help / WLanguage / WLanguage functions / Standard functions / HTML file management functions
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Converts an HTML string or buffer to a buffer containing a PDF document.
Example
sHTMLCode is string
// Convert HTML code to a PDF document
My_PDF_Doc is Buffer = HTMLToPDF(sHTMLCode)
Syntax
<Result> = HTMLToPDF(<Text in HTML format> [, <Page format> [, <PDF parameters>]])
<Result>: Character string
  • Buffer containing the PDF document resulting from the HTML conversion.
  • Empty buffer if an error occurs. To get more details on the error, use ErrorInfo.
<Text in HTML format>: Character string
Text to convert.
<Page format>: Optional integer
Page format of the generated PDF document:
iPaperSize_10x1410 x 14 inch paper
iPaperSize_11x1711 x 17 inch paper
iPaperSize_A3A3 paper (297 x 420 mm)
iPaperSize_A4
(Default value)
A4 paper (210 x 297 mm)
iPaperSize_A4SmallSmall A4 paper (210 x 297 mm)
iPaperSize_A5A5 (148 x 20 mm)
iPaperSize_GermanLGLFanfold paper (8.5 x 13 inches)
iPaperSize_GermanSTDFanfold paper (8.5 x 12 inches)
iPaperSize_B4B4 paper (250 x 354 mm)
iPaperSize_B5B5 paper (182 x 257 mm)
iPaperSize_FanfoldUSFanfold paper (14.875 x 11 inches)
iPaperSize_Envelope10Envelope #10 (4.125 x 9.5 inches)
iPaperSize_Envelope11Envelope #11 (4.5 x 10.375 inches)
iPaperSize_Envelope12Envelope #12 (4.5 x 4.5 x 11 inches)
iPaperSize_Envelope14Envelope #14 (5 x 11.5 inches)
iPaperSize_Envelope9Envelope #9 (3.875 x 8.875 inches)
iPaperSize_EnvelopeB4B4 envelope (250 x 353 mm)
iPaperSize_EnvelopeB5B5 envelope (176 x 250 mm)
iPaperSize_EnvelopeB6B6 envelope (176 x 125 mm)
iPaperSize_EnvelopeC3C3 envelope (324 x 458 mm)
iPaperSize_EnvelopeC4C4 envelope (229 x 324 mm)
iPaperSize_EnvelopeC5C5 envelope (162 x 229 mm)
iPaperSize_EnvelopeC6C6 envelope (114 x 162 mm)
iPaperSize_EnvelopeC65C65 envelope (114 x 229 mm)
iPaperSize_EnvelopeDLDL envelope (110 x 220 mm)
iPaperSize_EnvelopeItalyEnvelope 110 x 230 mm
iPaperSize_EnvelopeMonarchEnvelope 3.875 x 7.5 inches
iPaperSize_EnvelopePersoEnvelope 3.625 x 6.5 inches
iPaperSize_ExecutiveExecutive paper (7.5 x 10.5 inches)
iPaperSize_FolioFolio paper (8.5 x 13 inches)
iPaperSize_LedgerLedger paper (17 x 11 inches)
iPaperSize_LegalLegal paper (8.5 x 14 inches)
iPaperSize_LetterLetter paper (8.5 x 11 inches)
iPaperSize_LetterSmallSmall letter paper (8.5 x 11 inches)
iPaperSize_NoteNote paper (8.5 x 11 inches)
iPaperSize_QuartoQuarto paper (215 x 275 mm)
iPaperSize_StatementStatement paper (5.5 x 8.5 inches)
iPaperSize_TabloidTabloid paper (11 x 17 inches)
iPaperSize_CSheetSize C sheet
iPaperSize_DSheetSize D sheet
iPaperSize_ESheetSize E sheet
<PDF parameters>: Optional pdfParameter variable
Name of the pdfParameter variable that describes all the options of the PDF document to be generated.
Business / UI classification: Neutral code
Component: wd280std.dll
Minimum version required
  • Version 28
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/02/2023

Send a report | Local help