In a similar situation we decided to have the user initiate the
scanning in Paperport, play (stack, rotate) with the images until
satisfied, and then come to our form to index them. We enumerate the
PDF files in the folder, and upon save, we move each file to a server
location. As they are moved, they conveniently disappear from the
Paperport work surface.
-Tom.
>I've noticed the half dozen or so object libraries in the References list
>for PaperPort and thought I would try to automate the PaperPort 9
[quoted text clipped - 46 lines]
>Library: "PaperPortScannerConnectionLib"
>C:\Program Files\ScanSoft\PaperPort\ppscanmg.exe
deko - 04 Jan 2006 21:20 GMT
> In a similar situation we decided to have the user initiate the
> scanning in Paperport, play (stack, rotate) with the images until
> satisfied, and then come to our form to index them. We enumerate the
> PDF files in the folder, and upon save, we move each file to a server
> location. As they are moved, they conveniently disappear from the
> Paperport work surface.
I suppose the scripting runtime could be used to rename/move the newly
scanned files, and I could get the path like this:
Dim ppApp As PaperPortApplication
Dim ppFldr As PaperPortDiskFolder
Set ppApp = New PaperPortApplication
Set ppFldr = ppApp.DisplayedDesktopFolder
Debug.Print ppFldr.Path
But most documents are one-page invoices. It shouldn't be too difficult to
automate, if I could just get a connection to the scanner:
Dim lngClientWindow As Long
Dim strClientName As String
Dim ppCnx As ScannerConnection
Set ppCnx = New ScannerConnection
ppCnx.RegisterClient strClientName, lngClientWindow
But what is clientName and clientWindow?
And with whom or what am I registering these things with?
deko - 04 Jan 2006 21:50 GMT
I found an interesting debug program:
C:\Program Files\ScanSoft\PaperPort\ppdebug.exe
If I have ppdebug running when I open PaperPort, I get this output:
PAPRPORT: Creating scanner connection.
PAPRPORT: Scanner connection created.
PAPRPORT: Connected scanner connection sink.
PAPRPORT: Turned receive scans on
PAPRPORT: Registered client.
Interestingly, I get the same output when running my automation code, except
the automation code results in a nasty Run-time error because I don't know
what to do with this method:
Sub RegisterClient(clientName As String, clientWindow As Long)
I can only guess that the clientName is the path to the executable and the
clientWindow is the handle for the app window. But if I am trying to do
this via automation, what to use for a window handle? The Access app window
handle?