Hey ya`ll,
i`ve created a file called GUID.tmp. What I want to to now, is to rename that file to GUID.xml
How can achieve this?
Heres some code I use:
Thanx, StephanCode://write file string path = @"D:\Projects\x400_Adapter\Solution\Outbound\"+ partner + @"\" + mappedid + ".tmp"; StreamWriter finaldoc = new StreamWriter(path,false); finaldoc.Write(message); finaldoc.Close(); //rename file if(File.Exists(path)) { FileInfo Info = new FileInfo(path); Info.Name = Guid.NewGuid().ToString(); //this is not working:-) Name is read only! } return "OK";





Reply With Quote