Hello
Sorry if this is the wrong forum.
tsuji posted in the Win95/98 forum with a really helpfull script.
You save the vbs into a text file, and when you drag a file into the icon it copies the file to a number of locations set into the array.
Is it possible to ammend the script to delete the file you drag into the icon in all the locations?
If this is the wrong forum can you point me in the right direction
Sorry if this is the wrong forum.
tsuji posted in the Win95/98 forum with a really helpfull script.
You save the vbs into a text file, and when you drag a file into the icon it copies the file to a number of locations set into the array.
Code:
'Edit this input of target folders
aTargetFolder=array( "d:\abc", "d:\def", "d:\ghi")
if wscript.arguments.count=0 then wscript.quit(1)
set fso=createobject("scripting.filesystemobject")
on error resume next
for i=0 to wscript.arguments.count-1
for j=0 to ubound(aTargetFolder)
fso.copyfile wscript.arguments(i), fso.getfolder(aTargetFolder(j)).path & "\" & fso.getfilename(wscript.arguments(i)), true
if err<>0 then
wscript.echo wscript.arguments(j) & " is not a valid file, or " & aTargetFolder(j) & " is not a valid folder or file cannot be copied to itself. Copy aborted."
err.clear
end if
next
next
wscript.echo "Operation is done."
set fso=nothing
If this is the wrong forum can you point me in the right direction