THotPDF.Create Method

 

THotPDF.Create Method

THotPDF

 

顶部  上一页  下一页

Creates an instance of THotPDF.

 

Delphi 语法:

constructor Create( AOwner: TComponent ); override;

 

C++ 语法:

__fastcall virtual THotPDF( Classes::TComponent* AOwner );

 

说明

调用 Create 在运行时实例化 THotPDF 对象。构造函数分配 component instance,并初始化后续 PDF 生成使用的默认文档设置

 

代码示例


HPDF := THotPDF.Create( nil );
try
  HPDF.FileName := '.\Output.pdf';
  HPDF.BeginDoc;   // Start PDF document creation
  HPDF.CurrentPage.TextOut( 100, 100, 0, 'Hello World!' );
  HPDF.EndDoc;     // Finish and save PDF document
finally
  HPDF.Free;
end;

 

另请参阅: Destroy