|
REN
REN is short for "rename" and is used to rename files.
Renaming files is as bad as deleting or altering them.
Renaming system files can cause errors since the files point
to each other.
Syntax
rename [Drive:][Path] filename1 filename2
ren [Drive:][Path] filename1 filename2
Parameters
[ Drive : ][ Path ] filename1 : Specifies the location and
name of the file or set of
files you want to rename.
filename2 : Specifies the new name for the file. You
cannot specify a new drive or path when
renaming files.
Type in REN TEST.TXT TEST.DOC. This will
rename the text file you just created as an MSWord Document.
You may now open Word and edit the TEST file like any other
Word file. Type REN TEST.DOC MYFILE.DOC. This renames the
file as "myfile" but it is still an MSWord document.
Examples
To rename a file or directory named Chap10 to Part10, type:
ren chap10 part10
Batch File Commands
|