Does PCC have a command line version?

Jul 30, 2012 at 9:34 AM

Some advanced scanning software has the ability to launch another program after a scan is completed.  Would like to automatically paste the full path and filename of the newly scanned file to the clipboard, so that all the user has to do is paste. 

Jul 30, 2012 at 11:31 AM

FYI.  Ended up using Win7 builtin clip.exe with the following script to get the filename to the clipboard.

 

REM set LogFile=P:\TEMP\LogFiles\%~nx0.LOG
REM P:\DateTimeStamp.exe >> %LogFile% 2>&1
REM echo CurrentExecutingPath:  %CD%  >> %LogFile% 2>&1
REM echo %~f1 >> %LogFile% 2>&1
echo %~f1 | %WINDIR%\System32\clip.exe
REM echo. >> %LogFile% 2>&1

Coordinator
Aug 1, 2012 at 3:01 AM
rjt69 wrote:

Some advanced scanning software has the ability to launch another program after a scan is completed.  Would like to automatically paste the full path and filename of the newly scanned file to the clipboard, so that all the user has to do is paste. 


There is indeed a way to invoke Path Copy Copy via the command-line. It has been added in version 10.0. However, because I am lazy ;-), the documentation hasn't been updated yet for this version and so it isn't documented. Here is how to invoke it:

rundll32.exe path\to\PCCxx.dll,GetPathWithPlugin {commandId},path\to\convert

Where

path\to\PCCxx.dll is the path to the Path Copy Copy DLL installed for your system (if you're running a 64-bit OS, for example, this would most likely be C:\Program Files\Path Copy Copy\PCC64.dll),

{commandId} is the GUID corresponding to the Path Copy Copy command to invoke (there are documented here) and

path\to\convert is the actual file path to convert and then store in the clipboard.

As far as I know, nobody has used that new feature before, so let me know how it turns out for you.