How to get "Temp" folder path?
How can I get "Temp" folder path with C#.
I've looked up System.Environment.SpecialFolder,
but "Temp" wasn't there.
In win 9X the temp path is typically
"C:\Windows\Temp"
In windows 2000,XP
"C:\\Windows\User Name\Local Settings\Temp
My current dirty solution is,
Code:
string tempinternet=System.Environment.GetFolderPath(
System.Environment.SpecialFolder.InternetCache);
string temppath=tempinternet.Substring(0,tempinternet.LastIndexOf("\\"))
+"\\temp";
But is this safe?
Last edited by Sin Jeong-hun; October 6th, 2002 at 10:16 PM.
ALEA JACTA EST ET TEMPUS FUGIT