Jump to content


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.

Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.


How to create a folder in a batch file,( .bat) and delete it

  • Please log in to reply
3 replies to this topic

#1 blockie


  • Members
  • 10 posts
  • Local time:07:53 AM

Posted 20 July 2014 - 11:35 AM

The batch file I am creating needs a command to create a temporary folder and then delete it when no longer needed. can this be done? How?



BC AdBot (Login to Remove)


#2 wpgwpg


  • Members
  • 1,149 posts
  • Gender:Male
  • Location:US of A
  • Local time:10:53 AM

Posted 20 July 2014 - 11:48 AM

 Just use the mkdir command.  For the syntax just type mkdir /? from the command prompt.


Good luck.

Everyone with a computer should back his system up to an external hard drive regularly.  :thumbsup:

#3 JohnC_21


  • Members
  • 24,421 posts
  • Gender:Male
  • Local time:10:53 AM

Posted 20 July 2014 - 11:54 AM

Mkdir and Rmdir would be the commands.

#4 scotty_ncc1701


  • Members
  • 520 posts
  • Gender:Male
  • Local time:10:53 AM

Posted 20 July 2014 - 12:50 PM

To remove the folder and all contents:


RD [folder] /S /Q


Have a great day!

:bananas: :bounce:

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users