LoadFromFileA
Document management
Description
The trailing A denotes the ANSI (char) DLL entry point; the ActiveX/COM surface exposes only the Unicode form. Behaviour is identical to LoadFromFile and string arguments are interpreted using the current SetAnsiMode code page
Loads a PDF document from a file on disk. If the function succeeds, the loaded document is selected and its DocumentID can be retrieved using the SelectedDocument function
If the supplied password is rejected and OnPassword is assigned, the handler may provide another credential or cancel the load
Syntax
Delphi
Function DLLoadFromFileA(InstanceID: Integer; FileName, Password: PAnsiChar): Integer;
DLL
int DLLoadFromFileA(int InstanceID, const char* FileName, const char* Password);
Parameters
| FileName | The path and file name of the file to load. |
|---|---|
| Password | The password to open the file |
Return values
| 0 | The file could not be read or processed. Use the LastErrorCode function to determine the cause of the failure. |
|---|---|
| 1 | The file was loaded successfully |