Get Windows Temporary Folder

If you need to get windows temporary folder for your application you need to follow this steps.

function GetTempDirectory: String;
var
TempDir: array[0..255] of Char;
begin
GetTempPath(255, @TempDir);
Result := StrPas(TempDir);
end;

procedure TForm1.BitBtn1Click(Sender: TObject);
begin
label1.Caption := gettempdirectory;
end;
Download Source Code

Incoming search terms:

  • delphi get temp folder
  • delphi tempdir
  • gettempdirectory delphi
  • delphi temp folder
  • Delphi GetTempDirectory
  • delphi temp dir
  • get temp folder delphi
  • get tempdir delphi
  • get temporary name delphi
  • delphi xe2 windows temp
This entry was posted in Files, System. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Please copy the string Ldke4p to the field below: