Vb6 File System Object Move File

Vb6 File System Object Move File

I have a vbscript that I have written to move files from a source directory to a destination directory. The way the script works at the moment is that I have a mapping file which is read in (maps id's to folder type). Each file being moved begins with the id and the destination will be based on what the id is mapped to. I read in the mapping file and build up the destination path for each file being moved.

Vb6 File Copy

This all works as expected, the problem is when I try to move a file that already exists in the destination directory, the files are not moved from the source directory. Essentially I would like it to overwrite a file in the destination directory if it already exists. At the moment, my main command is this: fso.MoveFile ObjFile.Path, archiveTo & ' ' & yearValue & ' ' & monthValue & ' ' & ObjFile.Name Is there a way to default this to always overwrite a file in the destionation directory if it already exists? Federal government legal honors programs.

Object

Vb6 File Functions

Using the FSO (File System Object) in VB6. The programmer can use the FSO objects to create directories, move files, determine whether or not a Drive exists, etc. I want to move these files to folder B one. Move file from one folder to a different folder. For being too lazy to Google 'moving files in vb6' – mikerobi Oct.