| Description |
|
The GetTempFileName asks the Operating System to generate an empty unique temporary file that you can use as temporary storage. The returned string is the full path and file name of the temporary file.
|
|
| Microsoft MSDN Links |
System.IO
System.IO.Path
|
|
|
| A simple example |
program Project1;
{$APPTYPE CONSOLE}
uses
System.IO;
begin
Console.WriteLine('Temporary file path : ');
Console.WriteLine(System.IO.Path.GetTempPath);
Console.WriteLine;
Console.WriteLine('Temporary file name : ');
Console.WriteLine(System.IO.Path.GetTempFileName);
Console.Readline;
end.
| | Show full unit code | Temporary file path :
C:\DOCUME~1\Neil\LOCALS~1\Temp
Temporary file name :
C:\DOCUME~1\Neil\LOCALS~1\Temp\tmp1AE1.tmp
|
| |
|
|
|