pdfSetDocInfoEx
Set a document-info field, including (per the reference ABI's
| Category | Document metadata |
|---|---|
| Exported names | pdfSetDocInfoExA, pdfSetDocInfoExW |
| Availability | Partial — Key accepted but discarded, diCustom is single-slot and never serializes (see the chapter note) |
Purpose — Set a document-info field, including (per the reference ABI's intent) a named custom field via diCustom + Key.
Description — compatibility shim. Key is accepted in the exported signature but is never read by this build's implementation — it calls the exact same TLumasPdfDoc.SetDocInfo(DInfo, Value) as pdfSetDocInfo, ignoring Key entirely. Combined with diCustom's missing key mapping (chapter note above), a diCustom value set through this call is readable in-memory but never reaches the output file at all, and only the most recent call for diCustom survives regardless of Key.
Declarations
BOOL32 __stdcall pdfSetDocInfoExA(PPDF IPDF, TDocumentInfo DInfo, const char* Key, const char* Value);
BOOL32 __stdcall pdfSetDocInfoExW(PPDF IPDF, TDocumentInfo DInfo, const char* Key, const wchar_t* Value);
function pdfSetDocInfoExA(const IPDF: PPDF; DInfo: TDocumentInfo; const Key, Value: PAnsiChar): LongBool; stdcall; external 'LumasPdf.dll';
function pdfSetDocInfoExW(const IPDF: PPDF; DInfo: TDocumentInfo; const Key: PAnsiChar; const Value: PWideChar): LongBool; stdcall; external 'LumasPdf.dll';
Parameters
| Parameter | Type | Description |
|---|---|---|
IPDF | PPDF | Instance handle with an open document. |
DInfo | TDocumentInfo | Field to set. |
Key | PAnsiChar | Accepted but discarded — see Description. |
Value | string | New value. NULL is rejected. |
Return value — TRUE on success; FALSE if no document is open, Value is NULL, or the handle is invalid.
Remarks — For the ten standard fields (everything except diCompany/ diCustom), prefer the plain pdfSetDocInfo — the Ex suffix buys nothing extra in this engine.
See also — pdfSetDocInfo
C# (P/Invoke)
[return: MarshalAs(UnmanagedType.Bool)]
Setters
pdfSetDocInfoExA
pdfSetDocInfoExW
The …A form takes UTF-8, …W
takes UTF-16; a bare name aliases the ANSI form.
Worked examples — complete programs in ten languages.