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.

Photo

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

blockie

  • Members
  • 10 posts
  • OFFLINE
  •  
  • Local time:07:51 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?

 

Bill



BC AdBot (Login to Remove)

 


m

#2 wpgwpg

wpgwpg

  • Members
  • 1,149 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:US of A
  • Local time:10:51 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

JohnC_21

  • Members
  • 21,684 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:09:51 AM

Posted 20 July 2014 - 11:54 AM

Mkdir and Rmdir would be the commands.



#4 scotty_ncc1701

scotty_ncc1701

  • Members
  • 520 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:10:51 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