Skip to content

Built‐In Substitutions

9yz edited this page Aug 6, 2025 · 10 revisions

These substitutions are built into the program. To use them, wrap the substitution target in double brackets in one of the supported fields, then run the script through the right-click (context) or Tools menu. For example, typing [[tTime]] in the description of a file will replace it with the time the file was created (ex. 14:22). Likewise, [[mFileName]] will be replaced with the name of the file it is typed in (such as IMG_1234.jpg).

In addition to these substitutions, Text Substitutions also provides a variety of Functional Substitutions that calculate values and perform complex behavior.

Notes:

  • Built-in substitutions cannot be overwritten by user-created substitutions.
  • Built-in substitutions are all case-insensitive.

Creation Time Retrieval

Substitutions for accessing the time and date the file was created. Can either grab the date from the EXIF or IPTC date created setting, based on the "Get Creation Date From" preference.

tDate

The file's creation date in YYYY-MM-DD format.

tDatePretty, tDateP

The file's creation date in the format Monthname, day, year. Ex. November 1st, 1999.

tDatePrettyShort, tDatePS

The file's creation date in the format Monthabbr, day, year. Ex. Nov. 1st, 1999.

tDay

The numerical day of the month the file was created.

tDayPretty, tDayP, tDayOfWeek, tDOW

The day of the week the file was created.

Due to ExtendScript limitations, this will print what day it was at the time the file was created in the timezone your computer is set to.

tMonth

The numerical month the file was created.

tMonthPretty, tMonthP

The name of the month the file was created. Ex. November.

tMonthPrettyShort, tMonthPS

The abbreviation for the name of the month the file was created. Ex. Nov.

tYear, tYr

The year the file was created.

tYearShort, tYrS

The last 2 digits of the year the file was created.

tTime12

The 12-hour time the file was created. Ex. 4:37 pm.

tDayHalf, tAMPM

The day half the file was created (am or pm).

tTime, tTime24

The 24-hour time the file was created.

tTimeOfDay, tTOD

The name for the time of day the file was created.

  • 0:00-5:59 = night
  • 6:00-9:59 = morning
  • 10-13:59 = day
  • 14:00-16:59 = afternoon
  • 17:00-19:59 = evening
  • 20:00-23:59 = night

tHour, tHr

The hour the file was created.

tHour12

The 12-hour time the file was created.

tMinute, tMin

The minute the file was created. Includes a leading 0 for single-digit numbers.

tSecond, tSec

The second the file was created. Includes a leading 0 for single-digit numbers.

tDateTime, tDT

The date and 24-hour time the file was created. Ex. 2024-11-23 14:21.

tEXIFTime

The date, time, and timezone the file was created in ISO 8601 format, taken from EXIF. Ex. 2024-10-05T11:06:49.12-07:00

tIPTCTime

The date, time, and timezone the file was created in ISO 8601 format, taken from IPTC. Ex. 2024-10-05T11:06:49.12-07:00

Metadata Retrieval

Substitutions for accessing other properties of the file.

mFileName, mName, mFile

The system name for the file this value is a property of. Includes the file extension. Ex. IMG_1234.jpg.

mExtension, mFiletype

The file's extension, without a leading period. Ex. jpg.

mFileNameShort, mFileShort, mNameShort, mFileS, mNameS

The system name for the file this value is a property of. Does not include the file extension. Ex. IMG_1234.

mFolderName, mFolder

The name of the folder the file is in.

mTitle

The value in the IPTC Title property.

mHeadline

The value in the IPTC Headline property.

mDescription, mDesc

The value in the Dublin Core Description property.

mCreditLine, mCredit

The value in the IPTC Credit Line property.

mSublocation

The value in the IPTC Sublocation property.

mLocation

The values in the Country, State/Province, and City IPTC properties. Ex. United States, California, San Francisco.

mCity

The value in the IPTC City property.

mState, mProvince, mRegion

The value in the IPTC State/Province property.

mCountry

The value in the IPTC Country property.

mRating

The numerical star rating (0-5) of the file.

mRatingPretty, mRatingP

Stars representing the rating of the file. Ex. *** for 3 stars.

mLabel

The name of the label applied to the file.

mSource

The value in the Source property.

mCaptionWriter, mDescriptionWriter

The value in the Description Writer property.

mCopyrightNotice, mCopyright

The value in the Copyright Notice property.

mRightsUsageTerms, mUsageTerms

The value in the Rights Usage Terms property.

mJobIdentifier, mJobIdent, mJob

The value in the Job Identifier property.

mCreator

The value in the Creator property.

mCreatorJob

The value in the Creator: Job Title property.

mCreatorAddress

The value in the Creator: Address property.

mCreatorCity

The value in the Creator: City property.

mCreatorState, mCreatorProvince, mCreatorRegion

The value in the Creator: State/Province property.

mCreatorCountry

The value in the Creator: Country property.

mCreatorZip, mCreatorPostal

The value in the Creator: Postal Code property.

mCreatorPhone

The value in the Creator: Phone property.

mCreatorEmail

The value in the Creator: Email property.

mCreatorWebsite

The value in the Creator: Website property.

Camera Information Retrieval

Information about the image and the equipment used to take it.

cWidth, cW

The image's width.

cHeight, cH

The image's height.

cCamera, cCam

The model name of the camera used to take the photo.

cSerial

The serial number of the camera used to take the photo.

cLens

The model name of the lens used to take the photo.

cShutterSpeed, cShutter, cSS

The shutter speed the photo was taken at. Ex. 1/30

cAperture, cF

The aperture the photo was taken at. Ex. 2.8

cISO

The ISO the photo was taken at. Ex. 100

cFocalLength, cZoom

The focal length of the lens when the photo was taken. Ex. 50.0 mm

cFocalLength35, cZoom35

The 35mm-equivalent focal length of the lens. Format varies (or may not exist) based on the camera.

cExposureComp, cExpComp, cComp

The exposure compensation used when taking the photo. Ex. -2.00

Special-Purpose

"" (empty string)

If an empty string (string of 0 length) is processed, an empty string will be returned. Ex. [[]] will return .

Clone this wiki locally