Using the JAR file

When LexImgTk-x.x.jar is run from the command line, a scan profile is sent to the designated MFP. A listening port on the host computer remains open until the end user visits the MFP, selects the profile, and initiates a scan. Once the scan is initiated, scan data is sent to the specified output directory. There are eight parameters that can be used with the JAR to facilitate the imaging process, but only two are required.

Variable

Description

address

(required)

This is the IP address of the printer that scans the document.

file

(required)

This is the file name of the image or images to be returned by the printer.

Note: The file format is specified in the Scan Settings property file. If a file extension is supplied here, then it is ignored.

-l label

This is the text to display on the printer control panel for the profile. If a label is not supplied, then the file name is used.

-p settings_file

This is the name of the Scan Settings property file.

If a file name is not specified, then the JAR file looks for a file named “LexmarkImagingToolkit.properties.” If that file is not found, then the default values are used.

-s shortcut_number

This is the shortcut number for the profile created on the printer.

-r label

This removes the icon and profile for the specified label.

-v

This returns the version number for the LexImgTk-x.x.jar file.

-k

This specifies the port range in which the server socket can be created.


Note: When run from the command line, optional arguments such as [shortcut_number] will override corresponding values present in the scan properties file.

JAR file syntax

Purpose

Correct syntax

Example

To call the JAR file

java -jar LexImgTk-x.x.jar
[address] [file] -l [label]
-p [settings_file]
-s [shortcut_number]
-k [lower_port-upper_port]
java -jar LexImgTk-3.2.jar
198.162.0.10
"C:\temp\MyNewImage"
-l "My Job"
-p "C:\temp\MySettings.txt"
-s "7" -k "2100-2200"

To remove a profile

java -jar LexImgTk-x.x.jar
[address] -r [label]
java -jar LexImgTk-3.2.jar
198.162.0.10 -r "My Job"

To list the version number of the JAR file

java -jar LexImgTk-x.x.jar -v
java -jar LexImgTk-3.2.jar -v

Note: Make sure to replace x.x in LexImgTk-x.x.jar with the latest version number of the JAR file.