Skip to main content

File Naming Options in AnzioWin

Starting with AnzioWin version 15, file names used by AnzioWin can contain predetermined variable names that will get substituted for when the file is called or created.

Likewise, certain AnzioWin macro and script commands can contain and utilize these same replacement variables when the macro is executed.

This document covers the use of these environment replacement variables within the context of file names. See additional web pages for information on using these variables within macros and scripts.

One place where these are very useful is in the generation of both TIFF and PDF files from passthrough print jobs. Running these type of jobs can set the job up to simply increment an unique sequence number within the file name. These may not be very meaningful to the user and even less meaningful if they are going to be archived or emailed.

Fortunately we do have a few options to help force your own naming convention on new file names.

How the defaults work

There is a default file names used within AnzioWin when generating output files from print jobs. AnzioWin uses a file name predetermined file name, usually "Printwiz_Output", plus the appropriate extension, when creating a new file. As an example, when a PDF is generated by AnzioWin and no default file name was specified, the following would be the result:


If the file does exist, the file name will be incremented with a 4 digit number for each duplicate file name:


We create these files in AnzioWin's current working directory.

How to expand the file name

Custom file naming conventions are an easy way to separate one print job from another. These print jobs often come from applications or host system with no name information since they are meant to be printed.

AnzioWin has a solution. First, an output file name for AnzioWin can be specified by the host system or application by sending down an initial string setting the output type and name. Second, the user can set a default for the print-to name within the AnzioWin "printer-setup" dialog under the File menu. These file names can contain one or more replacement variables that represent runtime data, rather than hard-coded file names.

Below we discuss these methods and then we follow it up with a table of variables available for file names.

A. From "Printer setup"

In order to specify a file name, you do so through the Printer Setup dialog under the File menu. Here you can set defaults to use for PDF and TIFF generation, including setting the output directory and file naming convention. As an example, you might want the file name to contain today's date and be located in a archival directory:


PDF Printer Setup

This example shows setting the default for printing to be directed to a PDF with the date as part of the name.

B. From the host

A host application or script could also set the file type and naming convention prior to sending down a passthrough print command. This is done as an AnzioWin-specific command embedded within a certain hex sequence (for more information on host programming of AnzioWin, check out the Scripting AnzioWin from the Host knowledgebase article).

A host command might look like the following BASH script:

# First set the default printer type and a file name including the year and date
echo -e '\034printer "pdf://c:\\temp\\${ANZ_DATE_YY}_${ANZ_DATE_MM}.pdf" \$035"
# Now print the job
# ...

Note that in version 16 or higher you may be able to replace the back-slashes, which can be troublesome in some scripts, with a single forward-slash.

Likewise, on many UNIX / Linux operating systems, you can use the /usr/bin/ version of printf and separate the string into a different variable surrounded by single-quotes. This prevents back-slashes from being interpreted by the printf command, such as:

/usr/bin/printf "\034%s\035" 'printer pdf://c:\temp\${ANZ_DATE_YY}.pdf'

Expansion options

The table below lists the available replacement variables that can be used with AnzioWin. Some of these may not make sense to use in certain situations and may indeed be empty. Please test thoroughly before putting these into use.

Copyright © 2020 Rasmussen Software, Inc. Legal Information & Privacy Policy
Send comments and suggestions to