corgano Posted September 20, 2013 Share Posted September 20, 2013 I'm doing some automation using Acrobat and Excel I have a function I wrote for Excel that takes a bit of time to run, and I have to $oJSpdf.saveas($ImgFolder,"com.adobe.acrobat.jpeg") in acrobat. The .saveas method is a blocking function, which usually pauses the script until it has finished executing If I could start the Acrobat javascript.doc.saveas function and while that's running run the Excel function I wrote, It would save a good minute on the script. The saveas function in acrobat doesn't support this, so I was wondering Is there some way to run a blocking function and return before it finishes? 0x616e2069646561206973206c696b652061206d616e20776974686f7574206120626f64792c20746f206669676874206f6e6520697320746f206e657665722077696e2e2e2e2e Link to comment Share on other sites More sharing options...
MilesAhead Posted September 20, 2013 Share Posted September 20, 2013 Generally my suggestion would be to split the job into 2 scripts. Call the second script to do the file save and indicate when it's done perhaps using a windows message. RegisterWindowsMessage is quite easy to use. My Freeware Page Link to comment Share on other sites More sharing options...
TheSaint Posted September 21, 2013 Share Posted September 21, 2013 You could also probably get away with using the Adlib functions and/or even rely on a dynamic value in an ini file. Make sure brain is in gear before opening mouth! Remember, what is not said, can be just as important as what is said. Spoiler What is the Secret Key? Life is like a Donut If I put effort into communication, I expect you to read properly & fully, or just not comment. Ignoring those who try to divert conversation with irrelevancies. If I'm intent on insulting you or being rude, I will be obvious, not ambiguous about it. I'm only big and bad, to those who have an over-active imagination. I may have the Artistic Liesense to disagree with you. TheSaint's Toolbox (be advised many downloads are not working due to ISP screwup with my storage) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now