Jump to content

Recommended Posts

Guest joshboski
Posted

<quote/>

@echo off

FOR /F "tokens=1,2 delims=\ " %%A IN ('FSUTIL FSINFO DRIVES ^| MORE /

E /T0') DO (

REM Skip N:

IF "%%A"=="N" (

echo "skipping N"

) else (

echo "Deleting files from %%A"

del /S "%%A%\FILE1"

)

)

</quote>

  • Replies 1
  • Created
  • Last Reply

Popular Days

Guest Pegasus \(MVP\)
Posted

Re: batch if else

 

Answered in full in WindowsXP.general. Have a look

here http://www.blakjak.demon.co.uk/mul_crss.htm about

the merits of cross-posting versus multi-posting (which

wastes everybody's time), and consider whether this

question belongs into a server or perhaps into a scripting

newsgroup.

 

 

"joshboski" <josh.burkholder@gmail.com> wrote in message

news:ddc56032-1858-4ff8-b5e8-1bb054f4caa4@y38g2000hsy.googlegroups.com...

> <quote/>

> @echo off

> FOR /F "tokens=1,2 delims=\ " %%A IN ('FSUTIL FSINFO DRIVES ^| MORE /

> E /T0') DO (

> REM Skip N:

> IF "%%A"=="N" (

> echo "skipping N"

> ) else (

> echo "Deleting files from %%A"

> del /S "%%A%\FILE1"

> )

> )

> </quote>


×
×
  • Create New...