Variables in TOC Entries

This forum is for all Flare related Tips and Tricks.
Have a tip or trick you use while working in Flare? Share it here.
Post Reply
Bonnie Kern
Propeller Head
Posts: 29
Joined: Mon Mar 16, 2009 3:54 pm

Variables in TOC Entries

Post by Bonnie Kern »

The Flare v4.2 Help indicates variables can be used in TOC entries. However, a build of the output does not reflect the variablization. Instead, the entries display the mcvariable syntax, as entered according to the Help, which states:

Note: You can also rename a TOC entry and replace it with a variable from a variable set. To do this, click on the entry and highlight the text. Then replace it with this syntax: mcvariable:VariableSet.VariableName. For example, if your variable set is called "MyVariables" and you want to use a variable called "CompanyName," you would enter this as the name of the TOC entry: mcvariable:MyVariables.CompanyName.

The workaround we are using is as follows:
1. Include the variable in the topic title.
2. Drag the topic into the TOC. Viewing the topic properties from the TOC automatically adds the variable in the Appearance Label field on the Basic tab of this Properties dialog box.
3. View the topic properties from the Content Explorer, and in this Properties dialog box, remove the text in the Topic Title field.

Is there a better way that we are missing?
doc_guy
Propellus Maximus
Posts: 1979
Joined: Tue Nov 28, 2006 11:18 am
Location: Crossroads of the West
Contact:

Re: Variables in TOC Entries

Post by doc_guy »

Varibales can be used in TOC entries, however, they have to be newly added after Flare 4. So if you have entries that existed in your TOC in Flare 3, then the variable won't exist in the TOC in Flare 4.

What I do is this: I create the topic, then I edit it, adding the variable to the first heading in the topic. Once you've done that, then you can add the topic to the TOC, and the variable should be recognized.

If you've got a particluar variable in one topic TOC and you want it in another, you can copy the syntax from one properties setting in the TOC to another, and the same variable will work in both topic entries in the TOC.
Paul Pehrson
My Blog

Image
GregStenhouse
Sr. Propeller Head
Posts: 330
Joined: Tue May 13, 2008 3:27 pm
Location: Christchurch, New Zealand

Re: Variables in TOC Entries

Post by GregStenhouse »

The Flare help describes replacing an entire TOC entry with a variable. If you want to use a variable alongside text in the TOC, you must use this syntax:
Text [%=VariableSet.VariableName%]

For more info, see http://forums.madcapsoftware.com/viewto ... 438#p41438

Cheers
Greg
Post Reply