FLOWiki

(y)our wiki about all things technical communication

User Tools

Site Tools


flare:find_replace_text_and_insert_variables

Finding and replacing text and inserting variables

When using Flare, it is very important to fully take advantage of the advantages of Flare instead of using it as just another word processor. An important example of this is the use of variables.

A variable is a little bit of information, that frequently occurs in your document. Take for example your company’s phone number. Variables can also be useful in the early stages of your writing process when your terminology or features can change as the development process evolves.

Create a variable

First, you will have to create a variable:

  1. Open the Project Organizer.
  2. Double-click the Variables folder.
  3. Make a new Variable set or change the current one.
    For example: click to make a new variable in your variable set.
  4. Save all.

You have made a variable or variable set.

Replacing text with variables

But making a variable doesn’t mean that you have implemented them in your document. You have to replace the text that you made a variable for to that specific variable.

To replace text with your own created variables:

  1. Press Ctrl + F
    The Find and Replace in Files window appears.
  2. In the Find box, type the text you want to replace with one of your created variables.
  3. In the Replace with box, type the following: <MadCap:variable name=“variablesetname.variablename”/>.
  4. In the Find In list, click (whole project).
  5. In the File types list, click Topics.
  6. Select the Find in source code check box. Clear all other check boxes.
  7. Depending on how you want to replace your content, click Replace or Replace All.

Variables might be an easy way for automating your writing process, but be aware that you are replacing text by implementing one fixed element that can only be changed by changing your variable. This means that - no matter how your text is used in grammar or syntax - your variable will always stay the same.

This could cause a lot of trouble in the grammar of your document. Or even worse: when translating your document. So be aware when using variables and replacing your text with them.

Sources

flare/find_replace_text_and_insert_variables.txt · Last modified: 2017/03/30 13:16 (external edit)