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
application. The goal is to click a button and initiate a scan of a
document into a pdf file, programmatically name the file, and move it to a
particular folder. The problem is I have no documentation other than the
Object Browser.
When trying to connect to the scanner, I do this:
Dim ppCnx As ScannerConnection
Set ppCnx = New ScannerConnection
But before I go any further, I apparently need to register the client
(whatever that means).
If I try this:
Debug.Print ppCnx.ScannerConnected
I get a Visual Basic Run-time error:
"PaperPort error. The client called the Scanner manager before being
properly registered..."
Looking at the RegisterClient event in Object Browser, I see it takes 2
arguments:
Sub RegisterClient(clientName As String, clientWindow As Long)
So I think I need something like this:
ppCnx.RegisterClient("strClientName", lngClientWindow)
But what to use for clientName and clientWindow??
Any suggestions welcome. And if anyone can point me to PaperPort automation
sample code that would be great.
Thanks in advance.
Here are the libraries I'm trying to use:
Library: "PaperPortApplicationLib"
C:\Program Files\ScanSoft\PaperPort\PaprPort.exe
Library: "PaperPortFolderLib"
C:\Program Files\ScanSoft\PaperPort\PPFolder.dll
Library: "PaperPortScannerConnectionLib"
C:\Program Files\ScanSoft\PaperPort\ppscanmg.exe