Can't Wait
Can't Wait
- Subject: Can't Wait
- From: John McAdams <email@hidden>
- Date: Thu, 25 Oct 2001 13:48:41 -0400
Dear Scripters,
I'm having trouble getting Distiller and Acrobat coordinated. Acrobat
keeps trying to grab the file before it's finished distilling. I'm using
the following routine (su_disk is a property for the Startup disk):
--THIS ROUTINE HALTS THE SCRIPT UNTIL THE PDF IS FINISHED
on wait_till_PDF(job_name)
tell application "Finder"
activate
repeat 300 times
try
set PDFs_out to name of every file of folder (su_disk & "Watch
This:Out:" as alias) whose file type is "PDF "
if PDFs_out contains job_name then exit repeat
delay 2
on error
display dialog "No PDFs found in out folder!"
delay 2
end try
end repeat
end tell
end wait_till_PDF
I tried using the delay routine that Apple includes in some Folder
Action scripts but it was very slow and unreliable (although that could
be my fault). Any suggestions?
---------------------------------------
John McAdams
email@hidden