Thema: Delphi Folder creation datetime

Einzelnen Beitrag anzeigen

ASM

Registriert seit: 15. Aug 2004
165 Beiträge
 
Delphi 7 Enterprise
 
#2

AW: Folder creation datetime

  Alt 26. Mär 2013, 20:13
Did you try to parameterize the function DateTimeToStr() by including a variable of type TFormatSettings ?,
e.g.:
Delphi-Quellcode:
procedure TForm1.Button1Click(Sender: TObject);
Var tf: TFormatSettings;
begin
 GetLocaleFormatSettings(GetSystemDefaultLCID, tf);
 Showmessage(DateTimeToStr(GetFolderDate('c:\Windows'),tf));
end;
If that will fail, then are you absolutely shure calling for a time stamp of a truly existing foldername ? Curiously enough, if you are calling GetFolderDate() for an empty or nonexisting or misspelled foldername that will respond with a time stamp corresponding to '30.12.1899'.
  Mit Zitat antworten Zitat