UniqueString
Use this function to return a 45-character globally unique string.
Syntax
UniqueString ( )
There are no parameters for this function.
Keep in mind...
- These print drivers are supported: PCL5, PCL6, PST, MET, AFP, PDF, HTML, and RTF.
- These print drivers are not supported: EPT, MDR, and GDI.
- All platforms are supported, but note that while UniqueString is supported on z/OS, z/OS does not support PDF or long file names, so the PDF example does not apply to z/OS.
- Both multi- and single-step processing are supported.
The only DAL function actually involved in splitting the print stream is BreakBatch. The others make it easier to implement this functionality. For example, since you need to name the new print stream, you use the SetDeviceName procedure. To find the name of the current device, you use the DeviceName function. If you need to create unique file names, you can use the UniqueString function.
Note | While you can call all of these DAL functions in Documaker Server or Entry, the BreakBatch and SetDeviceName functions are not applicable in Entry since it does not use the batch printing engine. DeviceName and UniqueString are applicable to both Entry and Documaker Server. |
Example
Here is an example:
DataPath = GetINIString(,"Data","DataPath")
Drive = FileDrive(DataPath)
Path = FilePath(DataPath)
UniqueID = UniqueString()
Outputname = FullFileName(Drive,Path,UniqueID,".PDF")
SetDeviceName(Outputname)