Rename: Difference between revisions

From BR Wiki
Jump to navigation Jump to search
(Imported RENAME command page from old wiki)
 
 
(8 intermediate revisions by 2 users not shown)
Line 1: Line 1:
The '''Rename (REN)''' command renames or moves one or more files.
The '''Rename (REN)''' command renames or moves one or more files.


====Comments and Examples====
==Comments and Examples==
The following command renames the file TEST.1 to TESTPRO.1 and sends all messages that normally appear on the screen to the printer. Business Rules assumes that TEST.1 is in the default directory of the disk in drive B and that TESTPRO.1 is to remain in the same directory:
The following command renames the file TEST.1 to TESTPRO.1 and sends all messages that normally appear on the screen to the printer. BR assumes that TEST.1 is in the default directory of the disk in drive B and that TESTPRO.1 is to remain in the same directory:


  RENAME B:TEST.1 B:TESTPRO.1 PRINT
  RENAME B:TEST.1 B:TESTPRO.1 PRINT
Line 8: Line 8:
The next command moves the file ANDOVER from the default directory to the MICHIGAN directory:
The next command moves the file ANDOVER from the default directory to the MICHIGAN directory:


  RENAME C:ANDOVER C:\\MICHIGAN\\ANDOVER
  RENAME C:ANDOVER C:\MICHIGAN\ANDOVER


The following example moves all files in the current subdirectory of drive C to the \\STDNTS\\NAMES subdirectory on drive C. The original file name of each file is maintained:
The following example moves all files in the current subdirectory of drive C to the \STDNTS\NAMES subdirectory on drive C. The original file name of each file is maintained:


  RENAME C:*.* C:\\STDNTS\\NAMES\\*.*
  RENAME C:*.* C:\STDNTS\NAMES\*.*


====Syntax====
==Syntax==
[[Image:HELP0052.jpg]]
RENAME <old file name> <new file name> {[>[>]<output file>]|[PRINT]} [-<[[Rename option|option]]>][...]
 
[[Image:Rename.png]]
 
==Default==


====Default====
Display a log of performed actions on the screen.
Display a log of performed actions on the screen.


====Parameters====
==Parameters==
 
RENAME requires two parameters.
RENAME requires two parameters.


"Old file-ref" is the present name (and path, if required) of the file to be renamed.
'''Old file name''' is the present name (and path, if required) of the file to be renamed.


"New file-ref" is the new name (and path) of the file. Both parameters accept wildcard characters.
'''New file name''' is the new name (and path) of the file. Both parameters accept wildcard characters.


The optional ">file-ref" parameter saves the messages that normally appear on the screen during the renaming process to the file you specify in the file-ref.
The optional '''>redirected output file''' parameter saves the messages that normally appear on the screen during the renaming process to the file you specify in the file name.


"PRINT" sends screen messages to a printer.
'''PRINT''' sends screen messages to a printer.


Three optional parameters, when separated from the rest of the command with a dash, can follow the RENAME command:
'''-option''' may be any or all of the four optional parameters below. When used, they must be separated from the rest of the command with a dash:
:"N" |prevents the screen from displaying a log of performed actions.
:"P" |pause after the log of freed files fills one screen (press <CR> to see the next screen).
:"V" |requires the operator to Verify each renaming action before Business Rules performs it.
:"F" |force deletion of files when it is necessary in order to complete the rename process.


#'''N''' prevents the screen from displaying a log of performed actions.
#'''P''' pause after the log of freed files fills one screen. Press <ENTER> to see the next screen.
#'''V''' requires the operator to Verify each renaming action before BR performs it.
#'''F''' force deletion of files when it is necessary in order to complete the rename process.


<noinclude>
<noinclude>

Latest revision as of 17:42, 6 May 2014

The Rename (REN) command renames or moves one or more files.

Comments and Examples

The following command renames the file TEST.1 to TESTPRO.1 and sends all messages that normally appear on the screen to the printer. BR assumes that TEST.1 is in the default directory of the disk in drive B and that TESTPRO.1 is to remain in the same directory:

RENAME B:TEST.1 B:TESTPRO.1 PRINT

The next command moves the file ANDOVER from the default directory to the MICHIGAN directory:

RENAME C:ANDOVER C:\MICHIGAN\ANDOVER

The following example moves all files in the current subdirectory of drive C to the \STDNTS\NAMES subdirectory on drive C. The original file name of each file is maintained:

RENAME C:*.* C:\STDNTS\NAMES\*.*

Syntax

RENAME <old file name> <new file name> {[>[>]<output file>]|[PRINT]} [-<option>][...]

Default

Display a log of performed actions on the screen.

Parameters

RENAME requires two parameters.

Old file name is the present name (and path, if required) of the file to be renamed.

New file name is the new name (and path) of the file. Both parameters accept wildcard characters.

The optional >redirected output file parameter saves the messages that normally appear on the screen during the renaming process to the file you specify in the file name.

PRINT sends screen messages to a printer.

-option may be any or all of the four optional parameters below. When used, they must be separated from the rest of the command with a dash:

  1. N prevents the screen from displaying a log of performed actions.
  2. P pause after the log of freed files fills one screen. Press <ENTER> to see the next screen.
  3. V requires the operator to Verify each renaming action before BR performs it.
  4. F force deletion of files when it is necessary in order to complete the rename process.