The sample code is slightly off, here's the correct (tested!) script:
- Code: Select all
tell application "PDFpenPro"
open theFile as alias
tell document 1
ocr
repeat while performing ocr
delay 1
end repeat
delay 1
close with saving
end tell
end tell
I'm making this a new topic since the original title wasn't obvious that it helped with PDFPenPro. All credit goes to AppleSuperlatives.