There are four different naming profiles that control how the output file is named. Which naming profile is used depends on if you are creating serialized or multipaged output, and if you have the Save;UseJobID setting set to true. It is the combination of these settings that determines which profile is used to build the output filename.
The only exception to this is when file splitting by page count (Save;SplitFileEveryNPagesEnabled) or file size (Save;SplitFileWhenFileSizeExceedsThresholdEnabled) is enabled. When file splitting is enabled, the serialized naming profile is always used to name each file in the sequence. The file splitting options are only used when creating multipaged file types.
Serialized or Multi-page |
Include JobID |
Naming Profile |
---|---|---|
Serialized |
No |
Serialized |
Yes |
Serialized w/ JobID |
|
Multi-paged |
No |
Multi-page |
Yes |
Multi-page w/ JobID |
In most scenarios you will never need to change these values. Care must be taken when you do. The table below lists the settings to use to customize the output file naming. Table values in bold text are the default value for that setting.
Sample Profile |
|
<?xml version="1.0" encoding="utf-8"?> <Profile Type="0" DisplayName="Color TIFF 300dpi Named by Page Number" Description ="Create color TIFF named by page number"> <Settings>
<!-- Output file options --> <add Name="Devmode settings;Resolution" Value="300"/> <add Name="Devmode settings;Color" Value="1"/> <add Name="Save;Output File Format" Value="TIFF Serialized"/> <add Name="Advanced File Naming;Format string S" Value="%s"/> <add Name="Advanced File Naming;Variables S" Value="$(PrintedPageNumber)"/> ...
</Settings> </Profile> |
Code Sample - C# |
|
item.Set("Devmode settings;Color", "1");
item.Set("Advanced File Naming;Format string S", "%s"); item.Set("Advanced File Naming;Variables S", "$(PrintedPageNumber)"); |
Code Sample - VB.NET |
|
Dim item As PNDocConvQueueServiceLib.IPNDocConvQueueItem
' Create the conversion item item = New PNDocConvQueueServiceLib.PNDocConvQueueItem()
' Set conversion settings item.Set("Devmode settings;Resolution", "300") item.Set("Devmode settings;Color", "1") item.Set("Save;Output File Format", "TIFF Serialized")
item.Set("Advanced File Naming;Format string S", "%s") item.Set("Advanced File Naming;Variables S", "$(PrintedPageNumber)") ... ' convert the file item.Convert("Microsoft Word", _ "C:\Test\Report.docx", _ "C:\Test\Out\ConvertedReport") |
|
||||
---|---|---|---|---|
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
Variable |
Type and Format String Place Holder |
Description |
---|---|---|
$(Day) |
Numeric, %d |
The day in numeric format that the print job was submitted to the printer, from 1-31. |
$(DocumentPageNumber) |
Numeric, %d |
The page number of the document being printed. |
$(FileExtension) |
String, %s |
The file extension for the type of file being created. |
$(FileNumber) |
Numeric, %d |
The file number of the sequence of files. For multipaged output, this is always 1. For serialized output this is the number of the file in the sequence. |
$(Hour) |
Numeric, %d |
The hour in numeric format that the print job was submitted to the printer, 1-12 or 0-23 depending on your system preferences. |
$(JobID) |
Numeric, %d |
The unique JobID used by the printer. This is set to zero when the driver is first installed and is automatically incremented by the driver at the start of every print job. The JobID is often used to ensure that all files created have unique names. |
$(JobStatus) |
Numeric, %d |
The status of the print job, 1 for success, 0 for failure. |
$(MachineName) |
String, %s |
The name of the computer the print job is running on. |
$(Minute) |
Numeric, %d |
The minute in numeric format that the print job was submitted to the printer, from 0-59. |
$(Month) |
Numeric, %d |
The month in numeric format that the print job was submitted to the printer, from 1-12. |
$(OutputFileName) |
String, %s |
The contents of the $(OutputFileName) field. If this field is empty the name the printing application used when submitting the print job is used. |
$(PrintedPageNumber) |
String, %s |
The page number of the page being printed; this is not always the same as $(DocumentPageNumber). |
$(Second) |
Numeric, %d |
The second in numeric format that the print job was submitted to the printer, from 0-59. |
$(UserName) |
String, %s |
The name of the user who submitted the print job. |
$(Year) |
Numeric, %d |
The year in numeric format that the print job was submitted to the printer. |
Profile |
Format String |
Variables and Resulting File Names for TIFF Creation |
---|---|---|
Serialized |
%s_%3d |
$(OutputFileName) $(FileNumber)
C:\Test\Invoice_001.tif C:\Test\Invoice_002.tif C:\Test\Invoice_003.tif ... |
Serialized w/ JobID |
%3d_%s_%3d |
$(JobID) $(OutputFileName) $(FileNumber)
C:\Test\010_Invoice_001.tif C:\Test\010_Invoice_002.tif C:\Test\010_Invoice_003.tif ... |
Multi-page |
%s |
$(OutputFileName)
C:\Test\Invoice.tif |
Multi-page w/ JobID |
%3d_%s |
$(JobID) $(OutputFileName)
C:\Test\011_Invoice.tif |