The FileSystemObject VBA MoveFile function moves one or multiple files from current to destination location.
VBA MoveFile Syntax
fso.MoveFile( source, destination )
Current location of one or multiple files. You can use wildcards such as *.* to specify more than a single file matching the pattern, however, only matching part of the last component of the file path.
The destination location to which one or multiple files are to be moved.
VBA MoveFile Examples
Set fso = CreateObject("Scripting.FileSystemObject")
'Move OldFolderName to C:\Dst and rename to NewFolderName
fso.MoveFile "C:\OlderFolderName\Hello.txt", C:\Dst\NewFolderName\NewFileName.txt"
'Move all files matching wildcard to C:\Dst. This will keep their names
fso.MoveFile "C:\Src\Hello*.txt", C:\Dst\"