Views:

Product: LABEL MATRIX

Version: 2022 and earlier

 

Note: Depending on the edition of the software you are using, this functionality may not be available.

Label Setup Commands

File Name of Label to Print (/L=)

Number of Labels to Print (/C=

Start On Label (/R=

Number of Pages to Print (/P=)

Number of Duplicate Labels to Print (/D=)

Bypass Program Password (/E=)

Bypass Label Password (/LP=)

Log Error Messages to a File or Ignore Them (/G= or /G)

Lock File (/F=) or (/FL=)

Database Commands

Replace Datafile (/File=<internalName,path\datafileName>)

Number of Records to Skip (/S=)

Control Database Reanalyzing (/Z)

Print Job Commands

Redirect Printed Output to a Port or Printer Path (/O)

Specify Printer Name (/X)

Suppress Print Status/Cancel Dialog (/N)

Wait for Next Print Job (/W)

Run Separate Instance of LMWPRINT (/Y)

Minimize LMWPRINT (/M)

Close LMWPRINT (/Q)

Using LMWPRINT to run AutoPrint

Using LMWPRINT to control the Write Data function

Label Setup Commands

File Name of Label to Print (/L=)

The /L= command tells LMWPRINT which label to print by loading the file that matches the name you enter for the parameter. The full file name must be entered correctly or the file will not load. If you enter the file name without including the file extension, the QDF file extension is automatically appended to the file name.

Example:

LMWPRINT /L=product1.qdf

This command line will print the label which has product1.qdf as its file name.

Number of Labels to Print (/C=

The /C= command tells LMWPRINT the number of unique labels to print.

Example:

LMWPRINT /L=shipto.qdf /C=50

This command line will print 50 labels for the file having the shipto.qdf file name.

Start On Label (/R=

The /R= command tells LMWPRINT the exact label from which you would like to start printing when you have multiple labels on the page. This number must be between 1 and the total number of labels on the page.

The label number you should enter here will depend on the direction in which your labels are counted on the Label Properties Multiple tab. For example, if you have three labels across and you've set up the label direction to start at the top-left and go right, then if you tell the program to print starting on label 3 it will start on the top-right label. Conversely, if you have three labels across and you've set up the label direction to start at the top-right and go left, then if you tell the program to print starting on label 3 it will start on the top-left label.

Example:

LMWPRINT /L=shipto.qdf /R=3

This command line will tell the program to print starting with the third label.

Number of Pages to Print (/P=)

The /P= command tells LMWPRINT the number of pages to print. The parameter given for this command must be a numeric value.

Example:

LMWPRINT /L=customer.qdf /P=25

This command line will print 25 pages of the label with the customer.qdf file name.

 

Number of Duplicate Labels to Print (/D=)

 

The /D= command tells LMWPRINT the number of duplicate labels to print. The parameter given for this command overrides any Constant duplicate label settings in the design file (it will NOT override database or Keyboard origin duplicate settings).

Example:

LMWPRINT /L=office.qdf /C=50 /D=2

This command line will print a label with the office.qdf file name and print 50 labels with two duplicates of each label (for a total of 100 labels).

Bypass Program Password (/E=)

If you have set up security to require a password in order to use the program (Tools menu > Setup > Passwords tab), you can use the /E= command to tell LMWPRINT to bypass any user input required to allow automatic label processing. If you are required to enter a username and password to use the program and you do NOT include the /E= command, the program will display a dialog asking you to enter a username and password.

Example:

LMWPRINT /L=ex2.qdf /E=PSmith,golfball

This command line will print the label having the ex2.qdf file name, enter your username as PSmith, and enter your password as golfball.

Bypass Label Password (/LP=)

If you have placed password protection on a specific label design file (File menu > Label Properties > Security tab), you can use the /LP= command to tell LMWPRINT to bypass any user input required to allow automatic label processing. If you are required to enter a password to open the label design file and you do NOT include the /LP= command, the program will display a dialog asking you to enter a password.

Example:

LMWPRINT /L=ex2.qdf /LP=football

This command line will print the label having the ex2.qdf file name and enter the label password as football.

Log Error Messages to a File or Ignore Them (/G= or /G)

The /G command lets you specify a log file name for error messages. If this command is used, it will write error messages to the log file instead of popping up message dialogs requiring you to click OK. If the /G command is used without any parameters, it will ignore the error messages completely. The /G command needs to be supplied for each print job in which you want to send any error messages to a file.

Example:

LMWPRINT /L=quantity.qdf /C=75 /G=logfile.txt

This command line will tell LMWPRINT to print 75 of the quantity.qdf label and send any error messages to the logfile.txt log file.

Lock File (/F=) or (/FL=)

Note: The /F= command does NOT work in conjunction with AutoPrint.

The /F= command passes LMWPRINT a temporary "lock file" that will be deleted when the print job is finished.  The /F= command can be used with front-end applications such that the application looks for the existence of the lock file and as long as it is there, the application knows LMWPRINT is still printing.

The /F= command can also be used with front-end applications to handle timing issues when multiple LMWPRINT jobs are sent to the printer. For example, if the jobs are sent too quickly, data from the front-end may not be available for them, or the printer may still be busy with the first job and then the second job does not print because the printer was tied up.

The /FL= command serves the same purpose as /F=, but /FL= also opens the file so that the front-end application can try to delete the file until it succeeds, which means that the print job has either finished printing or errored out and released the file. The purpose is to be able to tell that the printing is complete if the print engine errors out and does delete the file.

To implement the /F= (or /FL) command

1.Via your front-end application, create a temporary file, which we will call the "lock file." The lock file can be any physical file on the computer and can have any file name. The important point to note is that LMWPRINT will delete this file when the print job is done.

2.Set up your front-end application to check for the presence of the lock file. When the file is no longer present you can then start up the next print job in your application. For example, you could set up a program loop that keeps checking for the file and as long as it finds it there, you know the print job has not been completed. Once the print job is finished and the file is deleted, you are ready to send another print job.

3.Add the /F= command switch to your LMWPRINT batch file or call it from your front-end application.

Example:

LMWPRINT /L=ex2.qdf /F=C:\lock.txt

This command line will tell LMWPRINT to print a label with the ex2.qdf filename and use a lock file called lock.txt that will be copied to the root of the C: drive.

Note: We cannot provide support for front-end applications or for writing/configuring these applications.

Database Commands

Replace Datafile (/File=)

The /File= LMWPRINT command allows you to replace an attached database file with a database file of the same format. It is important to note the difference in the two parameters required for this command: The first parameter, internalName, is the name of the database being replaced. This is NOT the actual file name, but the name you give the database in the program (normally entered on the last screen of the Add Database Wizard and can be viewed in the NAME column of the Database tab in the Label Properties tab dialog). The second parameter, path\datafileName, is the file name of the new database file. The format of this database file MUST be the same as that of the file being replaced. (As always, be sure to specify the label that the database is attached to by using the /L= command.)

Example:

LMWPRINT /L=send.qdf /File=customer1,cust2.dbf

You could enter this command line to print a label with the send.qdf file name, and replace the customer1 dBase format database (currently attached to the send.qdf label) with the cust2.dbf database at print time.

Number of Records to Skip (/S=)

The /S= command tells LMWPRINT how many records to skip if the file is pulling values from a sequential database. This command is useful if you have a database with a large number of records and have to stop the print job when you are only part way through the records. Using the /S= command, you can resume the print job right where you left off. The parameter must be a numeric value.

Example:

LMWPRINT /L=control.qdf /D=3 /S=15

This command line will print the label with the control.qdf file name, print three duplicates of each label, and skip records 1-15 of the database when printing.

Control Database Reanalyzing (/Z)

The /Z= commands allow you to control whether or not LMWPRINT should reanalyze any databases attached to the label.

When a /Z= command is NOT passed, LMWPRINT will check for changes to the database structure and display a prompt asking if you want to reanalyze.

/Z Command

Description

/Z=1

LMWPRINT will perform a check to see if any of the attached databases have changed, and if so it will automatically reanalyze the database.

A user interface will NOT be displayed.

/Z=2

LMWPRINT will NOT perform a check to see if any of the attached databases have changed and will NOT reanalyze.

/Z=3

LMWPRINT will ALWAYS reanalyze every database attached to the label, regardless of whether the database has changed or not.

A user interface will be displayed.

Note: Any other value passed with /Z= (including /Z without a value) will generate a command line parsing error.

Print Job Commands

Redirect Printed Output to a Port or Printer Path (/O)

For Printing Using Standard Serial or Parallel Ports

The /O LMWPRINT command will redirect printed output to a specified port. It allows changing of the port for the printer that was selected for the label design. The printer type and name must be the same for the printer on the newly selected port as the one selected in the label design. This command works best when you have two printers of the same model attached to your computer and wish to direct the print job to one printer or the other. For example, you can set up your label design for almost any Windows printer and then specify the proper one to print to at print time.

Example:

LMWPRINT /L=zlabel.qdf /O=LPT1:

This command line will tell LMWPRINT to print a label called zlabel.qdf to the printer on the LPT1: port.

For Printing Using TCP/IP or UNC Ports

The /O command becomes slightly more complex when printing using TCP/IP or UNC ports because it is more difficult for the program to determine what type of port is being requested. For this reason, when using these types of ports, an extra letter must be used in the command to distinguish the port type. The syntax is as follows:

/O Command

Port Type

Example

/OS=COMportname

Serial port

/OS=COM1:

/OP=LPTportname

Parallel port

/OP=LPT1:

/ON=\\servername\printername

UNC port

/ON=\\HAL9000\EasyCoderF4

/OI=TCP/IPport

TCP/IP port

/OI=192.168.10.143

/OI=TCP/IPport:port\ipp\queuename