here is everything i have
test.kix
Code:
Break On
Dim $SO
$SO=SetOption('Explicit','On')
$SO=SetOption('NoVarsInStrings','On')
$SO=SetOption('NoMacrosInStrings','On')
Dim $File
For Each $File In ReadFile('\\Server\Share\delete_these_files.txt')
If Exist('C:\Program Files\'+$File)
? 'C:\Program Files\'+$File
del "C:\Program Files\"+$File+"\*.*" /s /c
? @serror
rd "C:\Program Files\"+$File /q
? @serror
endif
next
Function ReadFile($file)
Dim $lf, $f, $_, $t
$lf=CHR(10)
$f=FreeFileHandle
$_=Open($f,$file)
If @ERROR Exit @ERROR EndIf
Do $t=$t+$lf+ReadLine($f) Until @ERROR
$_=Close($f)
$ReadFile=Split(SubStr($t,2),$lf)
EndFunction
here is the delete_these_files.txt file
Code:
hotties
and here is the error i get when running the script
Code:
C:\test.kix
C:\Program Files\Directory
The system cannon find the file specified.
The directory is not empty.
C:\Program Files
Access is denied.
The directory is not empty.
C:\
also the script deletes itself each time i run it