JCL Help:SHRenameFile

From Project JEDI Wiki
Jump to navigationJump to search


Summary

Renames a file.


Pascal

 function SHRenameFile(const Src: string; const Dest: string; Options: TSHRenameOptions): Boolean;


Parameters

Parameters Description
const Src: string Fully qualified name of the source file (the original name).
const Dest: string Fully qualified name of the destination file (the name to rename Src to).
Options: TSHRenameOptions Set of options that control the behavior of this function. See TSHRenameOptions for more information.


Return Value

If the function succeeds the result is True, otherwise it is False.


Description

SHRenameFile renames the specified file. Options allows you to control the behavior of the function. For example, if you specify [roRenameOnCollision] the function automatically modifies the destination filename in case the specified file already exists.


See Also

TSHDeleteOptions


About

Unit

JclShell


Donator

Marcel van Brakel


Notes

Use this function only to rename a single file.


Contribute to this help topic

This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page