Printer Driver Tips and Tricks -
Locating the generated files
Using the Black Ice printer
drivers, developers can specify any file name and/or output
directory that they want to use, and like any Black Ice
printer driver settings, these can be changed either
programmatically or via the user interface.
When specifying an output
folder specifically, it is important to ensure that the
printing user has write privileges to the folder specified.
Failing to have write access can cause one of two things,
printing to fail completely or for the file to be generated
in a different folder.
Locating the generated file
When the Black Ice printer
driver generates files, it will initially try to create the
files in the folder specified in the output directory
field., which can contain a standard path, for example
C:\output, or an environment variable, such as <<TEMP>>,
which will be parsed out to the associated path. If the
driver is unable to generate the file in the specified
folder, it will next try to create the file in the system
folder. If this attempt fails, the driver will lastly try
to generate the file in the root of the C: drive
Since the output folder can be
ANY folder, especially if developers allow their users
access to the output directory field, the Black Ice printer
drivers include a built in mechanism of reporting the folder
that the files were generated in.
Unless
disabled, the Black Ice printer driver will generate a group
file during each print job. The group file generated by the
Black Ice printer driver contains information about each
print job as well as the names of all of the files generated
by the Black Ice printer driver for that print job. The
Black Ice printer drivers can also launch an application
when printing is completed, and can pass a variety of
parameters to the launched application, including the name
and path of the group file generated for that print job.
The developed application can parse the group file (it is a
text based file) and retrieve the name(s) of the generated
files. The Group File is documented in the printer driver
manual, and you can also look at the OutputFileName sample
application included in the RTK
|