Hi,
I just went to incorporate the very useful pdfiumLib port into an existing project CPUX64.
(It has a relatively low memory footprint compared to other things I have tried)
https://forum.lazarus.freepascal.org/index.php?action=dlattach;topic=40938.0;attach=26219... First post in...
https://forum.lazarus.freepascal.org/index.php/topic,40938.msg303532.html#msg303532The example pdfium app that comes with the library for Lazarus has been working well, and I have been able to experiment with it, modify, and enlarge it successfully.
However when incorporating the control into an existing
CPUX64 Windows project, I suddenly get errors where I call windows.ShellExecute ...
main.pas(53,58) Error: Incompatible type for arg no. 4: Got "PWideChar", expected "PChar"
(Shell Execute works well when absolutely all references to pdfium are commented out).
I believe that it may be a
{Mode} string issue of some sort - but I can not track it down.
I've made a minimum project (attached) to try and show the problem.
You'll need to get the Pdfium.dll from Taazz's link, as its too big to include here.
https://github.com/pvginkel/PdfiumViewer/tree/releases/2.12.0.0/Libraries/Pdfium/x64Put it in the project directory.
The project will only compile if you comment out lines 53 and 54 removing the ShellExecuteAny help appreciated please as I would really like to use this pdfium control.
Paul
P.S.
I'm using TProcess meanwhile, but it does not cope with network paths ( e.g. \\copmuter\sharedfolder\etc ) and would like to solve it any way just incase I encounter a shellexecute PChar type problem else wise in my main project.