exitfoxitfoxit-reader

Exit command working for Foxit Phantom but not Foxit Reader


In a pdf file, in the code behind a button, I have

Run a JavaScript (change some form fields)
Execute a menu item, File->Save
Execute a menu item, File->Exit

The exit command works fine in Phantom PDF (older version, 2.2), but not in Foxit Reader (8.3, pretty recent version). Just nothing is happening there.

I also checked with an old Foxit Reader version, 3.3, and it is working as expected there.

I tried "Security" and "Trust Manager" settings, those don't improve the situation, though.

I want to close the reader when hitting the button.


Solution

  • This option (both creating and executing) seems to have been removed in new versions of Foxit Reader and Foxit PhantomPDF.

    Further to that, although Adobe Acrobat shows "Execute a menu item, File->Exit" as being an available option, it doesn't actually exit the application, just shows you the messagebox below and if you press OK it closes the PDF but leaves Adobe Acrobat open.

    enter image description here

    It's actually a good thing this doesn't work anymore, the document creator should not be able to trigger the viewing application on the end-users machine to quit. Trigger closing of document maybe, but definitely not the viewing application.