How to rename a file with string format in C#? -


this situation: created new file name using string format like:

string newfilename = string.format("{0}/{1}/{2}/{3}.txt", fileinfo.year,             fileinfo.month, fileinfo.day, fileinfo.time); 

and have another(old) file path: string path = @"c:\users\public\filename.txt" change or move old --> new. how that? possible change path of new? there can me. in advance

 string path = @"c:\users\public\filename.txt";   if (file.exists(path))             file.move(path, "destinationfilepath"); 

Comments

Popular posts from this blog

python - mat is not a numerical tuple : openCV error -

c# - MSAA finds controls UI Automation doesn't -

wordpress - .htaccess: RewriteRule: bad flag delimiters -