Quickscan: Command line TWAIN scanning


Using Quickscan

Quickscan is easy to use and as a standalone application is compatible with all development languagse. There are no DLLs, ActiveX or COM objects to install, just a single exe file which you can distribute with your application.

Using Quickscan is simple:
1: Decide which paramters you need to set (resolution, output etc) and populate the file quickscan.ini (or by using command line params)
2. Launch quickscan.exe and it will do the scanning and create the output file(s)
3. Monitor for the indicator file
4. Once the indicator file is present you can process the output file(s)

To view the technical document (PDF) with full details of all options and use click here: qs_tech.pdf (44kb) (right-click and select save target to save to local disk).

The indicator file
The indicator file is a file that is created after the scan is finished regardless of the outcome of the scan. There are 3 things that can happen when quickscan runs:
1. No pages are scanned (because of a problem or the user cancels)
2. A single page is scanned (on a flatbed scanner)
3. Multiple pages are scanned (on a ADF scanner)

In case 2 it will be very obvious to your application that the scan is complete (the output file is present), but in cases 1 and 3 it can be difficult to establish that the scan is complete. This is where the indicator file comes in useful and that is why your application should monitor for the indicator file rather than the output file.

This short example shows the indicator file being produced, even through the scan was cancelled:

Note that your application should delete the indicator file before Quickscan is called so that it will not get a false reading.
The alternative to using the indicator file is to wait until Quickscan has stopped running. Using the indicator file however means that your application can perform other tasks while waiting for the scan to complete.

Ini file or command line params?
Whichever you prefer!
Quickscan will work as well with the options being passed as command lime params or by pre-populating the ini file, the method of passing the options is entirely up to you.
For example, running the following command:
c:\scan\quickscan.exe selectscanner
is the same as entering the following line into quickscan.ini:

and then running quickscan.exe without any params.

If you use a combination of ini file entries and command line params then the command line params take priority. The combination is actually a very good way of using the same basic options (in the ini file) while tweaking them using the command line params. See the technical document, qs_tech.pdf (44kb) for more info.

The options
Please download and read the technical specifications to see the full list of options which can be used with Quickscan. They include resolution, output file format, output filename, scanner name and page layout.