Skip to main content

RenameLogicalFile

STD.File.RenameLogicalFile( filename, newname, [,allowOverwrite] )

filenameA null-terminated string containing the current logical name of the file.
newnameA null-terminated string containing the new logical name for the file.
allowOverwriteOptional. A boolean TRUE or FALSE flag indicating whether to allow the renamed file to overwrite an existing file of the same name. If omitted, the default is FALSE.

The RenameLogicalFile function changes the logical filename to the newname.

Example:

A := STD.File.RenameLogicalFile('Fred', 'Freddie');