The following example shows the top-level routine used to process a generated text file. An intermediate file is created during the process. The final result is stored in a subdirectory. Because the application is used by many people on a network, a fixed file name cannot be used. Instead it uses a temporary file whose name is generated by FUNIQUE( ).

parameter cFile // Name of file to process

local cTmpFile

cTmpFile = funique( "T???????.TMP" ) // Letter T followed by seven digits

preProcess( cFile, cTmpFile ) // Create intermediate temp file

mainProcess( cTmpFile, cFile ) // Create result file in subdirectory

erase ( cTmpFile ) // Erase temp file when done