A forum for questions or concerns related to the PDF-XChange Core API SDK
Moderators:TrackerSupp-Daniel, Tracker Support, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Tracker Supp-Stefan
Forum rules DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.
When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
Private Function OpenDocumentFromFile(sFilePath As String, pInst As LIBNAME.IPXC_Inst) As LIBNAME.IPXC_Document
Dim pDoc As LIBNAME.IPXC_Document = Nothing
Try
pDoc = pInst.OpenDocumentFromFile(sFilePath, Nothing, Nothing, 0, 0)
Catch ex As Exception
Dim hr As Integer = Marshal.GetHRForException(ex)
ShowErrMsg(hr)
Return Nothing
End Try
Return pDoc
End Function
Before I present an example available, I will describe the program sequence. A console application is started. The console application is waiting to process a PDF. With the launch IPXC_Inst::Init() is called, before exiting the console application IPXC_Inst::Finalize() runs.
The console application receives a message, processes the PDF and waits for the next request to process a PDF.
The PDF processing is implemented as a class from which an object is created. With this object, the PDF is processed.
Can I do it that way or do I need to outsource the processing of PDF in seperate program?
Is your console apllication a service?
Anyway we will need a complete sample to reproduce a problem. If you don't want to post it here you may send it to lazycat@tracker-software.com or support@pdf-xchange.com
Victor
Tracker Software
Project manager
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
It's not a service, but it runs all time. Sample is difficult because console application works with iSeries data queues.
Meantime i have outsource PDF processing in a separate program and there are no problems.
I was able to narrow the problem further. Before the PDF is processed with the Core API, that PDF is converted to PDF/A3 with the Driver API. I drop off the conversion, there are no problems.
Just spoke with Lzcat and he suspect that the problem could be several things - e.g. you are not waiting for the drivers API to finish it's work, but without seeing an actual example we can only guess.
In any case - we would not recommend you to do this - as even if the driver creates a PDF/A file - most Core API operations after that will break the compliance with the PDF/A format, and you will need to resave the file after modifying it with the Core API in the needed PDF sub-specification.