I want to create the Batch File to move executable files from a source directory and its sub-folders to another location.
Code:
# Script MoveExe.txt
var str source, destination, list, file
lf -r -n -g "*.exe" $source > $list
while ($list <> "")
do
lex "1" $list > $file
system move ("\""+$file+"\"") ("\""+$destination+"\"")
done
Script is in biterscripting. Save the script in file "C:/Scripts/MoveExe.txt". To call the script, type this command into biterscripting GUI.
Code:
script "MoveExe.txt" source("C:/testfolder1") destination("C:/testfolder2")
Will move all .exe files from the source directory "C:/testfolder1" and its sub-folders (see the -r flag) to the destination folder of 'C:/testfolder2".
Bookmarks