MoveFile - Rename a fileSynopsis:
string1 string2 MoveFile -> booleanExamples:
(Simulation1) (obsolete) MoveFile -> The File Simulation1Description:
is now called obsolete
Rename a file, e.g. link the file to the new nameParameters:
and unlink the old filename. If this unlink was the only link
to the file, the old file is effectively deleted.
Note that this is only guaranteed to work if new and old filename
refer to the same directory. Renaming over different directories
might work, but that's not POSIX and thus not portable.
string1 : Old FileBugs:
string2 : NewFile
boolean : A flag if operation succeded.
Since POSIX rename() did not work for some obscur reasons,Author:
MoveFile indeed works by linking the new filename and unlinking
the old one!
But that's exactly what rename() is supposed to do, no damage done...
Oct 12th 1999SeeAlso: