AppendToFile
Document management
Description
Appends changed objects to the specified source PDF as an incremental update
Use the same file that supplied the selected document through LoadFromFile, LoadFromString, or LoadFromStream
The target length must match the loaded source length; a mismatch is rejected before writing because incremental offsets would be stale
Use SaveChanges for safe in-place saving and automatic reloading of the updated xref chain
Syntax
Delphi
Function TPDFlib.AppendToFile(Const FileName: WideString): Integer;
ActiveX
Function PDFlib::AppendToFile(FileName As String) As Long
DLL
int DLAppendToFile(int InstanceID, const wchar_t* FileName);
int DLAppendToFileA(int InstanceID, const char* FileName);
Parameters
| FileName | The source PDF file that receives the incremental update |
|---|
Return values
| 0 | The incremental update could not be appended to the specified file |
|---|---|
| 1 | Success |
Remarks
The selected font, text size, colours, line settings and content layer are unchanged by the save, so drawing can continue on the selected page without having to choose them again
Only objects that were changed or created are written; reading pages, text, images or form fields does not add them to the update
When the document holds signature fields, the modification date is not updated automatically, because the permission check of a signature counts a rewritten information dictionary or metadata stream as a change to the document. A date set with SetInformation is still written