?
Solved

need help with Batch file

Posted on 2011-03-10
3
Medium Priority
?
259 Views
Last Modified: 2012-05-11
Need to have the batch file run without prompting for a "YES" or "NO"

C:\>del  \\test01\test\test

\\test01\test\test\*, Are you sure (Y/N)? y

Thanks
0
Comment
Question by:Sean
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 7

Accepted Solution

by:
enzogoy earned 2000 total points
ID: 35100301
Do you really need a batch file?  If not then you can run this command from the command prompt.  Work really well.

@DEL /S /Q /F "\\test\test\test\*.*"

The above command will delete all files in that test folder.  It won't pop up to ask you to confirm.
0
 
LVL 7

Assisted Solution

by:enzogoy
enzogoy earned 2000 total points
ID: 35100446
@echo off
del /Q /S /F "\\testing\testing\testing\*.*"
exit

save it as a batch file ... will do the job too.
0
 
LVL 1

Author Closing Comment

by:Sean
ID: 35185826
Thank you.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

VALIDATING DATES One method of validating dates is to jam the date into the DATE command and see if it accepts it by examining the system's errorlevel value. A non-zero result indicates failure. A typical example might look something like the fol…
Introduction: Recently, I got a requirement to zip all files individually with batch file script in Windows OS. I don't know much about scripting, but I searched Google and found a lot of examples and websites to complete my task. Finally, I was ab…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses
Course of the Month11 days, 22 hours left to enroll

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question