Menu

Command line support for batch scanning

2018-01-17
2018-11-09
  • Veli-Matti Niinioja

    Hi,
    it would be nice to use command line interface for batch scanning, too. It would be easier to scan multi-page or duplex documents.

    Thanks!

     
  • Ben Olden-Cooligan

    What feature(s) from batch scan do you want to be added to the CLI?

     
  • Veli-Matti Niinioja

    For batch scan at least:

    • use an existing profile where autosave is enabled
    • Multiple scans (prompt between scans).
    • Save to a single file

    I've written a couple of batch scripts (Windows 10), one for PDF and one for JPG, with autosave enabled. After scanning the script opens the scanned document.

    This is my PDF script (nircmd from Nirsoft required):
    if not DEFINED IS_MINIMIZED set IS_MINIMIZED=1 && start "" /min "%~dpnx0" % && exit
    SET SCANDIR=D:\Documents\Scanned
    "C:\Program Files (x86)\NAPS2\NAPS2.console" -a -p "PDF"
    start "Scanned" %SCANDIR%
    pushd %SCANDIR%
    for /f "eol=: delims=" %%F in ('dir %SCANDIR% /b /od
    .pdf') do @set "newest=%%F"
    start "%newest%" "%newest%"
    D:\Documents\nircmd win activate title "Scanned"
    D:\Documents\nircmd win activate stitle "%newest%"
    exit

    For batch scans I had to make another profile without autosave and use the NAPS2 gui.

    Thanks!

     

    Last edit: Veli-Matti Niinioja 2018-01-22
  • SteveJay

    SteveJay - 2018-09-12

    The comand line worksw great for a quick scan but it would be great if there was a switch to just bring up the scan another page dialogue. Any likelyhood.
    Ather than that a great tool.

     
  • Markus

    Markus - 2018-11-09

    Anybody know how to open NAPS2 with a Document?

    NAPS2.exe "MyScan.PDF"
    and
    NAPS2.exe -i "MyScan.PDF"
    didn't work.

    I don't know how to use the Keys on my Canon Pixma MX925. The Driver that works with that keys make a PDF or a JPG or TIF and open a Programm after that, so I can't use NAPS2 with that keys from Scanner till better commandline support is give to the GUI of NAPS2.

     

Log in to post a comment.