Arbortext Command Language > Functions by Alphabetical Listing > temp_name
  
temp_name
$tempfile = temp_name(name[, ext[, dir]])
This function creates a new temporary log file. The name parameter specifies the base name for the file. The optional ext parameter specifies the extension to use for the file name. If the ext parameter is omitted, it defaults to .log.
The optional dir parameter specifies the where to store the new temporary file. If the dir parameter is omitted, it defaults to the value of the environment variable TMPDIR. If TMPDIR, is not set, it defaults to the c:\temp directory.
The return value is the name of the newly created temp file. Note that this function will automatically append a number (1 to 99) to the end of the base file name as necessary to avoid duplicate file names.
Be aware that another process could feasibly create a file with the same name in the time between when this function is called and when the file is actually created.