Expression Evaluator
The Expression Evaluator lets you test dynamic values before you run a command, script, task, or rename rule.
Use it when you want to confirm what a placeholder, PDM variable, or string function will become at runtime.
What It Helps With
The evaluator is useful for previewing:
- File and folder placeholders such as
$fileName,$filePath, and$folderPath. - Vault and user placeholders such as
$vaultName,$username, and$username.email. - Date and time placeholders such as
$date,$time,$yyyy, and$timestamp. - PDM variables such as
[Description]or$(Description.@). - String functions such as
${before(...)},${replace(...)}, and${regex(...)}. - Revision functions such as
${revision()},${nextRevision()}, and${revisionComponentValue("ComponentName")}. - Expressions that will later be used in commands like
rename,setvar,bom,export,msgbox, oruntil.
Why Use It
The evaluator previews the result without changing files, setting variables, checking files in, renaming anything, or writing back to the vault.
This makes it a safe place to test expressions before using them in production automation.
How To Use It
- Open the Expression Evaluator from the PDMShell toolbar.
- Choose a PDM file or folder when the expression depends on file or folder context.
- Choose a configuration when the expression depends on configuration-specific variables.
- Choose a variable when you want
$valueto use the current value of that variable. - Type or choose the expression to test.
- Review the evaluated result.
Examples
$fileNameWithoutExtension
[Description]
${before($fileNameWithoutExtension, "-")}
${replace($value, "DRAFT", "RELEASED")}
${regex($fileNameWithoutExtension, "^([^-]+)-", 1)}
${revision()}
${nextRevision()}
${revision("$folderPath\\$fileNameWithoutExtension.pdf")}
File Context
Some expressions need a selected PDM file or folder to return a meaningful result.
Examples:
| Expression | Needs file or folder context |
|---|---|
$fileName |
Yes |
$filePath |
Yes |
$folderPath |
Yes |
[Description] |
Yes |
${revision()} |
Yes |
${nextRevision()} |
Yes |
${revisionComponentValue("ComponentName")} |
Yes |
${revision("C:\Vault\File.pdf")} |
No, if the path is complete and the vault is logged in |
$vaultName |
No, if logged in |
$date |
No |
$guid |
No |
$tempFolder |
No |