Hello all, I'm perplexed here really. This is in Delphi 7
I Have a snippet
var U:string; UserPath:string; begin U := GetCurrentUserName;
My get Username works fine calling on a function I wrote however when I am attempting to insert that username in a directory path it wont place the ending???
procedure TSpUser.SpeedButton7Click(Sender: TObject); var U:string; UserPath:string; begin U := GetCurrentUserName; UserPath := 'C:\Documents and Settings\' + (U) + '\Local Settings\Temp\'; PlaySound('type', hInstance, SND_RESOURCE or SND_SYNC); Label9.Caption:=UserPath; end;
What I get is C:\Documents and Settings\users name but the \Local Settings\Temp\ just wont show????
Am I missing something really simple here?
Thanks if you can help