PDF-XChange Viewer SDK for Developer's
(ActiveX and Simple DLL Versions)
Moderators:PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange
I am trying to use some Named Operations that were added to the SDK fairly recently, DeletePages and InsertPages. My code isn't working and the documentation is not helping me to figure out what is wrong. I can't find anything in the code examples either. My code looks like this:
The value of nDocumentID comes from OpenDocument - I do this because the documentation for DeletePages says there is one required argument which is "The unique identifier of the document or full file name of the document."
The call to DoVerb does not generate an error, but it doesn't delete the page either.
DoDocumentVerb(docId, "", "DeletePages", dataIn, dataOut, 0);
// or
DoVerb("Documents[#<docId>]", "DeletePages", dataIn, dataOut, 0);
// dataIn - can be empty in both cases.
Cheers
PDF-XChange Co. LTD (Project Developer)
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
I used the DoDocumentVerb method and now the code is working, sort of... it is actually bringing up the Delete Pages dialog, which is not what I expected. I assumed that having set the values for Operations.DeletePages, it would perform the operation using the supplied parameters rather than invoking the end-user dialog.
Please clarify how these operations work. Thanks -