## Placeholders

Within the following functions and input fields, the FileRenamer allows using placeholders: Mask, Search and Replace, Insert Text, Delete Text and Append Text.

The placeholders are replaced by what they stand for during renaming depending on the corresponding file or folder, time or list position. Placeholders can be combined with arbitrary other characters and they can also be used within regular expressions. Of course, the same placeholder can also be used several times in the same field.

At the moment, the following placeholders from the following categories are available in the FileRenamer:

A list of all available placeholders can also be found in the program under Name > Mask and Extension > Mask. Here you can also copy the placeholders directly to the clipboard for use.

## File Name and Folder

Placeholders holding the name and path of the file.

%name% | Old Name of File |

%name,x,y% | Old Name of File from character x to character y. For example, %name,1,3% corresponds to the first three characters of the file name, %name,2,5% corresponds to the second through fifth character. |

%ext% | Old Extension of File |

%ext,x,y% | Old Extension of File from character x to character y |

%folderX% %folder‑X% |
The placeholders %folder1%, %folder2%, %folder3% up to %folder50% as well as %folder-1%, %folder-2%, %folder-3% up to %folder-50% are standing for the names of the folders in which the file is stored. Positive numbers like in %folder1% count the folders from the drive to the file, negative numbers like in %folder-1% count the other way around. Accordingly, the placeholder %folder1% is standing for the first folder of the path, %folder-1% is standing for the first folder below the file. When having the file C:\Holidays\Trips\Norway\Image100.jpg %folder1% will be replaced with "Holidays", %folder-1% with "Norway", when renaming the file. Correspondingly, the placeholder %folder2% is standing for the second folder in the path, this is "Trips" in that case (%folder-2% would be the same, counted from the top). You can find some examples how to use the folder placeholders in this tutorial. |

## Numbering

Placeholders allowing a file numbering.

%num% | Number / Position of File within the list; the initial value, the increment and the number of leading zeros can be adjusted in the settings |

%0num% | Number / Position within the list with one leading zero (for example 01) |

%00num% | Number / Position within the list with two leading zeros (for example 001) |

%000num% | Number / Position within the list with three leading zeros (for example 0001) |

%0000num% | Number / Position within the list with four leading zeros (for example 00001) |

%00000num% | Number / Position within the list with five leading zeros (for example 000001) |

%0...0num% | Number / Position within the list with any number of leading zeros |

%abs0num% | Number / Position within the list with a number of leading zeros fitting to the total number of files in the list (1 to 9 for up to 10 files; 01 to 99 for 10 to 99 files; 001 to 999 for 100 to 999 files and so on) |

%abs% | Absolute Number of Files that are currently in the list |

## Current Date and Time

Placeholders referring to the current date and time.

%date% | Current date in the format "year-month-day" (two or four digits with leading zeros if necessary; short form for %yyyy%-%mm%-%dd%) |

%dd.mm.yyyy% | Current date in the format "day.month.year" (two or four digits with leading zeros if necessary; short form for %dd%.%mm%.%yyyy%) |

%yyyy-mm-dd% | Current date in the format "year-month-day" (two or four digits with leading zeros if necessary; short form for %yyyy%-%mm%-%dd%) |

%time% | Current time in the format "hour-minute-second" (two digits with leading zeros if necessary; short form for %hh%-%ii%-%ss%) |

%hh-mm-ss% | Current time in the format "hour-minute-second" (two digits with leading zeros if necessary; short form for %hh%-%ii%-%ss%) |

%hh-mm% | Current time in the format "hour-minute" (two digits with leading zeros if necessary; short form for %hh%-%ii%) |

%yyyy% | Current Year written with four digits |

%yy% | Current Year written with two digits |

%mm% | Current Month, always two digits, leading zeros if necessary |

%m% | Current Month, one or two digits without leading zeros |

%dd% | Current Day, always two digits, leading zeros if necessary |

%d% | Current Day, one or two digits without leading zeros |

%hh% | Current Hour, always two digits, leading zeros if necessary |

%h% | Current Hour, one or two digits without leading zeros |

%ii% | Current Minute, always two digits, leading zeros if necessary |

%i% | Current Minute, one or two digits without leading zeros |

%ss% | Current Second, always two digits, leading zeros if necessary |

%s% | Current Second, one or two digits without leading zeros |

## Last Modification

In order to use the last modification date of the the file or folder as placeholder, we can add the extension "-m" to the placeholders for the current time and date.

%date-m% | Last modification date in the format "year-month-day" (two or four digits with leading zeros if necessary; short form for %yyyy-m%-%mm-m%-%dd-m%) |

%dd.mm.yyyy-m% | Last modification date in the format "day.month.year" (two or four digits with leading zeros if necessary; short form for %dd-m%.%mm-m%.%yyyy-m%) |

%yyyy-mm-dd-m% | Last modification date in the format "year-month-day" (two or four digits with leading zeros if necessary; short form for %yyyy-m%-%mm-m%-%dd-m%) |

%time-m% | Last modification time in the format "hour-minute-second" (two digits with leading zeros if necessary; short form for %hh-m%-%ii-m%-%ss-m%) |

%hh-mm-ss-m% | Last modification time in the format "hour-minute-second" (two digits with leading zeros if necessary; short form for %hh-m%-%ii-m%-%ss-m%) |

%hh-mm-m% | Last modification time in the format "hour-minute" (two digits with leading zeros if necessary; short form for %hh-m%-%ii-m%) |

%yyyy-m% | Last Modification Year written with four digits |

%yy-m% | Last Modification Year written with two digits |

%mm-m% | Last Modification Month, always two digits, leading zeros if necessary |

%m-m% | Last Modification Month, one or two digits without leading zeros |

%dd-m% | Last Modification Day, always two digits, leading zeros if necessary |

%d-m% | Last Modification Day, one or two digits without leading zeros |

%hh-m% | Last Modification Hour, always two digits, leading zeros if necessary |

%h-m% | Last Modification Hour, one or two digits without leading zeros |

%ii-m% | Last Modification Minute, always two digits, leading zeros if necessary |

%i-m% | Last Modification Minute, one or two digits without leading zeros |

%ss-m% | Last Modification Second, always two digits, leading zeros if necessary |

%s-m% | Last Modification Second, one or two digits without leading zeros |

## Creation Date

For using the file or folder creation date as placeholder, we can add the extension "-c" to the placeholders for the current time and date.

%date-c% | Creation date in the format "year-month-day" (two or four digits with leading zeros if necessary; short form for %yyyy-c%-%mm-c%-%dd-c%) |

%dd.mm.yyyy-c% | Creation date in the format "day.month.year" (two or four digits with leading zeros if necessary; short form for %dd-c%.%mm-c%.%yyyy-c%) |

%yyyy-mm-dd-c% | Creation date in the format "year-month-day" (two or four digits with leading zeros if necessary; short form for %yyyy-c%-%mm-c%-%dd-c%) |

%time-c% | Creation time in the format "hour-minute-second" (two digits with leading zeros if necessary; short form for %hh-c%-%ii-c%-%ss-c%) |

%hh-mm-ss-c% | Creation time in the format "hour-minute-second" (two digits with leading zeros if necessary; short form for %hh-c%-%ii-c%-%ss-c%) |

%hh-mm-c% | Creation time in the format "hour-minute" (two digits with leading zeros if necessary; short form for %hh-c%-%ii-c%) |

%yyyy-c% | Year of Creation written with four digits |

%yy-c% | Year of Creation written with two digits |

%mm-c% | Month of Creation, always two digits, leading zeros if necessary |

%m-c% | Month of Creation, one or two digits without leading zeros |

%dd-c% | Day of Creation, always two digits, leading zeros if necessary |

%d-c% | Day of Creation, one or two digits without leading zeros |

%hh-c% | Hour of Creation, always two digits, leading zeros if necessary |

%h-c% | Hour of Creation, one or two digits without leading zeros |

%ii-c% | Minute of Creation, always two digits, leading zeros if necessary |

%i-c% | Minute of Creation, one or two digits without leading zeros |

%ss-c% | Second of Creation, always two digits, leading zeros if necessary |

%s-c% | Second of Creation, one or two digits without leading zeros |

## Last Access

Like for the modification date and creation date placeholders, the suffix "-a" is standing for the last access to the file or folder.

%date-a% | Last access date in the format "year-month-day" (two or four digits with leading zeros if necessary; short form for %yyyy-a%-%mm-a%-%dd-a%) |

%dd.mm.yyyy-a% | Last access date in the format "day.month.year" (two or four digits with leading zeros if necessary; short form for %dd-a%.%mm-a%.%yyyy-a%) |

%yyyy-mm-dd-a% | Last access date in the format "year-month-day" (two or four digits with leading zeros if necessary; short form for %yyyy-a%-%mm-a%-%dd-a%) |

%time-a% | Last access time in the format "hour-minute-second" (two digits with leading zeros if necessary; short form for %hh-a%-%ii-a%-%ss-a%) |

%hh-mm-ss-a% | Last access time in the format "hour-minute-second" (two digits with leading zeros if necessary; short form for %hh-a%-%ii-a%-%ss-a%) |

%hh-mm-a% | Last access time in the format "hour-minute" (two digits with leading zeros if necessary; short form for %hh-a%-%ii-a%) |

%yyyy-a% | Last Access Year written with four digits |

%yy-a% | Last Access Year written with two digits |

%mm-a% | Last Access Month, always two digits, leading zeros if necessary |

%m-a% | Last Access Month, one or two digits without leading zeros |

%dd-a% | Last Access Day, always two digits, leading zeros if necessary |

%d-a% | Last Access Day, one or two digits without leading zeros |

%hh-a% | Last Access Hour, always two digits, leading zeros if necessary |

%h-a% | Last Access Hour, one or two digits without leading zeros |

%ii-a% | Last Access Minute, always two digits, leading zeros if necessary |

%i-a% | Last Access Minute, one or two digits without leading zeros |

%ss-a% | Last Access Second, always two digits, leading zeros if necessary |

%s-a% | Last Access Second, one or two digits without leading zeros |

## Sources

Sources offer the opportunity to use the lines of a text for renaming a series of files or folders in the FileRenamer. You can open the window for entering the text using the menu "Sources > Text Source".

%textsource-line% | Complete content of the entire line from the text source window, which line number corresponds to the position of the file to be renamed in the file list. |

%textsource-line,x,y% | Letter x to letter y of the line from the text source window, which line number corresponds to the position of the file to be renamed in the file list. For example, %textsource-line,1,5% for the first 5 letters of the line or %textsource-line,3,7% for the letters at the character positions 3 to 7 of the line. |

You can find out more about the use of resources as well as some application examples for their use in the tutorial about the use and the usage options of resources in the FileRenamer.