For those who remember, here is a recap. (and for those who don't, here is the synopsis)
I have a working script that exports a pdf to a desired document path. It also renames the file as I desire. These files consist of a placed image file in page 1 and another in page 2.
The exported pdf sometimes does not image these. I thought the problem was due to exporting to a server.
The real cause is if I click the mouse button or try to input any other commands in InDesign, a blank page will result in the pdf. If I run the script and wait for it to finish, it performs correctly. This happens both when saving to a server or saving to the local drive.
Question: Is there a way with JS to tell InDesign to ignore any commands until it finishes running?
Any other workarounds suggestions? (besides not clicking on any keys until finished )