How to Define a Custom Text Variable in Adobe InDesign
See Adobe InDesign: Tips and Tricks for similar articles.
Text variables are dynamic text content that can change with context. There are some standard text variables in InDesign that can be used for job-tracking, such as File Name and Modification Date. Custom variables can also be created by users. In this example, I'll create a variable based on a paragraph style to be used as a running footer.
- In the Type menu, go to Text Variables and choose Define.

- The dialog box shows the standard variables listed on the left. Click Running Header and then click New.

- Running Header is a variable that's already set up to be based on a paragraph style. In the next dialog box, it's simply a matter of naming the variable, selecting the paragraph style, and setting the options. Once you have done so, click OK.

- The new variable is now listed in the Text Variables dialog box. Click Done.

- To use the variable, I've created a text frame on a master page with the text cursor inserted. Go to the Type menu, scroll down to Text Variables, then to Insert Variable, and choose the custom variable.

- In the text frame on the master, only the variable name will appear.

- On document pages that have text with that paragraph style applied, that text content appears.

