I need local variables (specific to a topic)

This forum is for all Flare issues not related to any of the other categories.
Post Reply
stealth94rt
Propeller Head
Posts: 41
Joined: Thu Feb 02, 2006 2:10 pm

I need local variables (specific to a topic)

Post by stealth94rt »

I'm working on a command reference that contains 3 topics with nearly identical text. There are only a few words in each that differ based on the particular topic. It would be ideal if I could declare a few local variables at the top of each topic and then use snippets for all the common text -- the snippets would contain the variable names and get the local values from each topic to handle the word differences. Unfortunately, it looks like Flare does not provide a way to create topic-level variables. If I did it with JavaScript or similar, it would likely only work with web outputs and I also need PDF.

Does anyone have suggestions or workarounds for something like this?
LTinker68
Master Propellus Maximus
Posts: 7247
Joined: Thu Feb 16, 2006 9:38 pm

Re: I need local variables (specific to a topic)

Post by LTinker68 »

I think you can do what you want with snippet conditions. I haven't had a need to use them myself, but from what I've read on the forums, I think they'll do what you want.
Image

Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
dmcleod
Propeller Head
Posts: 13
Joined: Fri Mar 02, 2012 5:01 pm

Re: I need local variables (specific to a topic)

Post by dmcleod »

Yeah, snippet conditions will work here. You'd create one snippet with all of your text in it. Then you'd condition the topic specific text for each one inside this snippet, and make your three different topics with this same snippet in it, with the snippet conditions applied to each topic.
Post Reply