Batch Script - Renaming Folders


Advertisements

For renaming folders, Batch Script provides the REN or RENAME command.

Syntax

RENAME [drive:][path][directoryname1 | filename1] [directoryname2 | filename2]

Let’s look at some examples of renaming folders.

Examples

ren Example Example1

The above command will rename the folder called Example in the current working directory to Example1.

ren C:\Example Example1

The above command will rename the folder called Example in C Drive to Example1.

batch_script_functions.htm
Advertisements