RenameFile

Renames a file.


Syntax

FileSystem.RenameFile(File, NewName)


Parameters


File

String, input



File to be renamed.


NewName

String, input



New name of file.


Example

Sub Main()

FileSystem.RenameFile "C:\Users\Public\My Directory\OldFile.txt", "NewFile.txt"

End Sub