sys.tempfile([prefix])

Create a temporary empty Directory Object, created in the user temporary folder.

Parameters

prefix

An optional string that contains the first 3 letters of the temporary directory name.

Return value

Returns a File Object that represents a temporary file located in the Windows system temporary path. In case of error, this function return nil.

Example

local temp = sys.tempdir() print("Temporary directory path: "..temp.fullpath)