|
program PDFInfo; {$APPTYPE CONSOLE} uses SysUtils, Graphics, Classes, HPDFDoc;
var HPDF: THotPDF;
begin HPDF:= THotPDF.Create(nil); try HPDF.AutoLaunch := true; // The PDF file will be shown automatically HPDF.ShowInfo := true; // Include information into document HPDF.FileName := 'Hello world.pdf'; HPDF.Author := 'http://www.loslab.com/'; // Set the author information HPDF.Subject := 'HotPDF console information demo'; // Set the document subject HPDF.Title := 'Information Demo'; // Set the document title HPDF.BeginDoc; // Create the PDF file HPDF.CurrentPage.TextOut(10, 10, 0, 'Information Demo'); // Print the text HPDF.EndDoc; // Close the PDF file finally HPDF.Free; end; end. |