THotPDF.AddImageFromFile Method
Adds image from file data to the image embedding workflow. The call creates or attaches the PDF-side object needed by later output, validation, signing, or page rendering steps
Declaration
function AddImageFromFile(FileName: TFileName; Compression: THPDFImageCompressionType; IsMask: boolean= false; MaskIndex: Integer= - 1): Integer;
Unit
HPDFDoc
Parameters
| Name | Purpose |
|---|---|
FileName | File path used as the source or destination for this operation |
Compression | Input used by AddImageFromFile |
IsMask | Input used by AddImageFromFile |
MaskIndex | Zero-based index or object index used to select an existing item |
Return value
Returns an Integer value
Usage notes
- Use this API in the image embedding workflow before the affected page, resource, field, or catalog object is finalised
- Keep object names, field names, resource names, and returned handles stable until the document is finalised