Search directory for a specific keyword or a file type and move files to new location using VBScript and batch file
Description: Search all files that has a filename as the keyword from a source folder and move files to the new destination folder
First, You’ll start by editing the search-move-files.vbs file.
- Open the vbs file using your favorite file editor.
- Change the SourceFolder path to your SourceFolder path. Example: C:\User\Ron\Downloads\
- Change the DestFolder path to your DestFolder path. Example: C:\User\Ron\Desktop\New Folder\
- Change keyword to your new-keyword Examples: .xlsx or .jpg or image
- Save and close search-move-files.vbs.
Secondly, edit the Run-Seach-Move-Program.bat file.
- Open the BATCH file using your favorite file editor.
- Update the path of your vbs file.
- Save and close Run-Seach-Move-Program.bat.
Lastly, Run the Program
- Double cLick Run-Seach-Move-Program.bat to execute the vbs program.
- Wait for vbs to finish the task.
- Watch as windows copies your files to your new location.