I have a HP L7590 all-in-one device. HP now officially supports it only through the Snow Leo interface, that is image capture.
First off, when I use BonJour, then the scanner appears under Shared in Image Capture (IC), but is not found in DTPO before I select it in IC. Can be found if I use USB
When I try to use from inside DTPO, It scans everything in the feeder before I have much option to change settings, shows me the first scanned page and allows me to add it, but nothing more happens. Looks like if does a preview on everything in the document scanner. I just want to scan.
So for now I need to scan in Image Capture, and need to get a workflow / automator action set up on a folder to have it auto-import and OCR into DTPO.
PS: Support for multiple languages is listed. I keep my OS in English, but I would like to use a danish version of the application. How do I get that to work ?
I wanted to set up a folder action to automatically import and OCR PDF files I drop in a Scan folder from Image Capture.
But, there is no Automator action to import using OCR directly from the filesystem. And importing the file first, and then OCR it gives me 2 copies in the database. Of course I can have my Automator action delete the first copy, but this is sub-optimal.
There is an AppleScript action ‘ocr’ which will import with OCR, thus bringing only one copy into DTPO. Will you release an automator action for this ? Or should I do it myself ? (I have done little OS X and iPhone programming, but no automator actions before).
I also consider using the Run Applescript automator action for doing this. But the Automator action would be great.
Check the Extras > Workflow Examples folder on the distribution disk for a workflow that uses an AppleScript based action as an example for OCR conversion.
Works fine if I run from inside automator, using Get Selected Finder Items / Get Specified Finder Items as first step.
As soon as it runs a Folder Action, it switches to DTPO, but nothing more. Here is my modified script. any idead what goes wrong ? Does a folder action send the Finder items in a different format ? Is there any log I can look in ? Or write to ?
on run {input, parameters}
local output, aRecord
set output to {}
tell application id "com.devon-technologies.thinkpro2"
-- set destinationGroup to incoming group of inbox
repeat with aRecord in input
with timeout of 3600 seconds
try
set newRecord to ocr file (aRecord as string)
set output to output & {newRecord}
on error errMsg number 9104
-- Possible errors that are returned (numbers subject to change):
-- kNoImageRecordError = 9102
-- kExportImageRecordError = 9103
-- kPDFImportFailedError = 9104
-- kUnknownExceptionError = 9105
-- kInsufficientResolutionError = 9106
-- kDemoLimitExceededError = 9107
-- kOCREngineFailureError = 9108
log message errMsg info (name of aRecord) & ": Check “~/Library/Caches/DEVONthink Pro/OCR” for files that weren't imported"
end try
end timeout
end repeat
end tell
-- Returns successfully converted records (to be moved aside)
return output
Please don’t forget that for a Folder Action the “Get Selected Finder Items” is useless. The input for your workflow are the items that were dropped in the folder, so you can start with the ocr action right away.
But why don’t you use the “OCR Items” action? It takes image files as input so you don’t need an AppleScript for that. The only reason you might want to run an AppleScript is to specify a group in your script without having the windows change in DT2 (as is the case with the “Set Current group” action).
The problem is with my Snow Leopard. It will not run any folder actions. Seems like something not completely unusual. First there was the Adobe osax component that needed updating, then QuickTime Broadcaster errors, then com.apple.pbs, and some more stuff. A whole series of small things I fixed one after another, but I did not succeed. Why does it need to be so complicated. I have filed a bug report with Apple.
I did a re-install of Snow Leo on top of my existing 10.6, with no luck.
Tonight I will update my time machine backup, and do a clean install, so hopefully it will work tomorrow.
I can now confirm, that my problem is with the OCR automator action.
If I have the OCR in my workflow, then I always will get this error in my console log:
09/10/09 16.17.55 com.apple.FolderActions.enabled[373] launchctl: CFURLWriteDataAndPropertiesToResource(/var/db/launchd.db/com.apple.launchd.peruser.502/overrides.plist) failed: -10
I can run other actions, and the rest of my action works fine if the OCR step is removed.