Deleting Multiple Network files
I need to create a script that will delete 2 files on a local pc, but also delete 4 files on another (networked\pathed) pc. I would like to use WISE, if possible. At this point, I would be interested in any script that would work. I have even tried a batch file. Here is the batch script just so you guys get an idea what I am trying to do. I am using the correct pathing, but can not get the network files to delete. I am pushing this job to the Kcm-altiris1 computer. I am using Altiris as my deployment tool obviously.
del /F /s "\\kcm-altiris1\Images\Base Images\basexp.002"
del /F /s "\\kcm-altiris1\Images\Base Images\basexp.img"
del /F /s "\\kcm-altiris2\Images\Base Images\basexp.002"
del /F /s "\\kcm-altiris2\Images\Base Images\basexp.img"
del /F /s "\\kcm-altiris2\Images\Base Images\non sysprep\basexp.002"
del /F /s "\\kcm-altiris2\Images\Base Images\non sysprep\basexp.img"
Once again, I would like to use WISE if possible.
Thanks
del /F /s "\\kcm-altiris1\Images\Base Images\basexp.img"
del /F /s "\\kcm-altiris2\Images\Base Images\basexp.002"
del /F /s "\\kcm-altiris2\Images\Base Images\basexp.img"
del /F /s "\\kcm-altiris2\Images\Base Images\non sysprep\basexp.002"
del /F /s "\\kcm-altiris2\Images\Base Images\non sysprep\basexp.img"
Once again, I would like to use WISE if possible.
Thanks
0 Comments
[ + ] Show comments
Answers (2)
Please log in to answer
Posted by:
knight
19 years ago
HI,
If you want, you can use vb script to delete files on your network drive.
Here is a sample script;
dim filesys
Set filesys = CreateObject("Scripting.FileSystemObject")
If filesys.FileExists("\\kcm-altiris1\Images\Base Images\basexp.002") then
filesys.DeleteFile "\\kcm-altiris1\Images\Base Images\basexp.002", True
End If
Set filesys = Nothing
Hope this one helps.
knight [;)]
If you want, you can use vb script to delete files on your network drive.
Here is a sample script;
dim filesys
Set filesys = CreateObject("Scripting.FileSystemObject")
If filesys.FileExists("\\kcm-altiris1\Images\Base Images\basexp.002") then
filesys.DeleteFile "\\kcm-altiris1\Images\Base Images\basexp.002", True
End If
Set filesys = Nothing
Hope this one helps.
knight [;)]
Posted by:
rikx2
19 years ago
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.