Search found 4 matches

by fr33z3r
28 May 2009 17:09
Forum: DOS Batch Forum
Topic: Solved: .bat file doesn't work
Replies: 6
Views: 8787

I did it like this

Code: Select all


rd /s /q "C:\measuringresults\%name%"

set name=%

goto begin


and it worked. Still, thanks a lot for your help

Grts
by fr33z3r
24 May 2009 01:53
Forum: DOS Batch Forum
Topic: Solved: .bat file doesn't work
Replies: 6
Views: 8787

thx I used :endloop2 if not defined name echo Nothing left to delete. && goto end this works great if the folder measuringresults is empty before running the file. If however the folder contains subdirectory A, B and C and the diskspace is too small then name = A A gets deleted name = B B ge...
by fr33z3r
22 May 2009 14:52
Forum: DOS Batch Forum
Topic: Solved: .bat file doesn't work
Replies: 6
Views: 8787

Thanks man! I got to the following code, and it's very close to what I want. The line you gave me to skip the list file didn't work, but this one does @echo off color f0 :begin fsutil volume diskfree c: > C:\temp.txt setlocal for /f "tokens=1*" %%a in (C:\temp.txt) do ( set vri...
by fr33z3r
22 May 2009 13:34
Forum: DOS Batch Forum
Topic: Solved: .bat file doesn't work
Replies: 6
Views: 8787

Solved: .bat file doesn't work

Hi guys I'm new here and not used to writing batch files I tried writing a file that does the following start: IF the free diskspace on C:\ is over 2GB do nothing ELSE delete the alfabetically first subdirectory of C:\measuringresults jump to start END IF END I created the following file NOTE that t...