Windows 7 Forfiles "del @file" using wrong path for delete

  • Thread starter Thread starter Shitironman
  • Start date Start date
S

Shitironman

I have a batch using forfiles command to regularly delete old files.forfiles /p C:\A\B\C\D\E\ /s /m *.abc /d -10 /c "cmd /c del @file" It works well so far on 5 PCs (WIN7 and WIN10), but on one (also Win7) doing it wrong:Finds the file, so echo @Path is C:\A\B\C\D\E\file1.abc is goodthen it tries to delete from one folder up C:\A\B\C\D\file1.abc for some reason. Not a surprise, it will fail as cannot find file.Do you have any idea what could be the issue with this one particular PC? Could be some evil windows setting?Note: Del @path seemingly does the job, but still,

Continue reading...
 

Similar threads

R
Replies
0
Views
11
Rafisher1
R
C
Replies
0
Views
5
Captjoe777
C
P
Replies
0
Views
12
PYANAGAWA
P
L
Replies
0
Views
26
Luis Soriano _ER
L
Back
Top