Overwrite file in folder
gurus out there help?
'file search for
targetacquired = olddmcl
'source , destination folders
source = "c:\test1\"
dest = "c:\test2\"
set fso = createobject _
("scripting.filesystemobject")
'get files in source folder
set folder = fso.getfolder (source)
set files = folder.files
'loop through files
'if file called dmcl
'copy dest folder
each file in files
if file.name = targetacquired then
wscript.echo file.path
file.copy dest, true
end if
next
wscript.echo "dmcl file updated !"
hi timm32,
as issue seems related development/coding, focus on file services , storage question here, not best support resource development. quick , better support on scripting/coding, recommend initial new thread further support in msdn forum. community members , support professionals there more familiar script , can give support in efficient way.
for convenience, have list link msdn forum.
msdn forum
http://social.msdn.microsoft.com/forums/en-us/categories/
thanks understandings.
this posting provided "as is" no warranties, , confers no rights.
Windows Server > Windows Server General Forum
Comments
Post a Comment