This window is displayed when you choose the Rename command from the Command menu. You can use this window to rename one or more files in the active folder. In order to use this command, first select one or more files you want to rename in the active panel; the renaming will not occur for the files that you did not select. This window contains the following areas:

Selection/File/Folder

This read-only area displays information about the objects to be renamed.

In Folder

This read-only area displays the full path to the active folder that contains the source files to be renamed.

From

The file name or mask that specifies the set of files which should be renamed. The star character (*) means "any character" and can appear in place of the file name, extension, or both. For example, *.doc means "any file with any name and the extension doc". Letter.* means "any file with the name Letter and any extension"; *.* means "any file", and Letter.doc means only one particular file named Letter.doc. Note that the mask applies only to the files you have selected in the active panel before choosing the Rename command from the menu. The the files that you did not select will not be renamed even if their file names match the mask. If you want the mask to apply to all files of the active folder, select all of them before choosing the Rename command from the menu.

To

The new name or mask to rename the destination object(s) during the operation. (See the Remarks section below for more information). If this area is empty, or contains the *.* mask, no renaming occurs.

Use "star-for-star" mask matching

If this option is selected, then the "star-for-star" mask matching is used when renaming the files. If this option is not selected, then the "traditional" mask matching is used. (See the Remarks section below for more information).

Replace # symbol(s) with auto-incrementing number

If selected, this option causes AB Commander to replace the # symbols (if specified in the file name of the To area) with consecutive numbers, starting with the value you have specified. If you enter several # symbols next to each other, AB Commander will pad the resulting value to the left with zeros, as needed, when renaming the files. For example, if the value of the file counter happens to be 15 for a particular file, then ### will be replaced with 015. However if the actial size of the counter exceeds the number of #'s you've specified, the full number will be used.

If this option is not selected, then each # symbol in the destination file name is treated just like any other character.

Reuse the starting value

If this option is selected, then AB Commander will remember the starting value you have specified and use it again the next time you use the Rename command. If this option is cleared, then AB Commander will advance the starting value to the next unused number, ready for use the next time you choose the Rename command.

Remarks

When renaming several files in the same operation, the new name of each file is formed based on the existing name of the file, the masks entered in the From and To area, and whether the "star-for-star" mask matching option has been selected or not. The basic algorithm of making a new name is as follows:

1. The contents of the To mask is separated into two components, the first part is used to produce the new "name", the second one is used to produce the new "name extension" (separated with a dot).

2. In each of the two components, the star character (*) is replaced with the appropriate part of the existing file name component. If the "star-for-star" mask matching option has NOT been selected, then the "traditional" mask matching is performed: the star character is replaced with the whole existing file name component. If the "star-for-star" mask matching option has BEEN selected, then the star character is replaced with the part of the existing file name component that matches the star character in the From mask. (See examples below).

3. The two new "name" and "name extension" components are combined together to make the new "full" file name, which is assigned to the file.

For example, suppose the active panel contains the following two files which you want to rename:

and you have entered the following masks into the Rename dialog:

If the Use "star-for-star" mask matching option is cleared, the when renaming the file ABC1.TXT, the first star character in the mask DEF*GHI.* is replaced with the whole original "name", ABC1, and the second star is replaced with the existing "name extension" TXT, which produces the new name DEFABC1GHI.TXT. For the second file, ABC2.ASC, the same procedure gives the new name DEFABC2GHI.ASC.

If, however, the Use "star-for-star" mask matching option is checked, then the From mask ABC*.* is applied to the file, ABC1.TXT, and the first star in that mask gets the value of 1, while the second star gets TXT. These values are substituted in place of the stars of the To mask, making the new name for this file to be DEF1GHI.TXT. When the same From mask is applied to the second file, ABC2.ASC, the stars get the values 2 and ASC, appropriately, which, after being applied to the To mask, produce the new name for the second file: DEF2GHI.ASC


Move Delete Copyright © 2024, WinAbility® Software Corporation  . All rights reserved