Using Conditional Tags to Hide Text

This forum is for all Flare issues not related to any of the other categories.
Post Reply
BWallace
Jr. Propeller Head
Posts: 2
Joined: Wed Oct 18, 2017 10:38 am

Using Conditional Tags to Hide Text

Post by BWallace »

Forgive me if this has already been asked somewhere, as I have looked and been unable to find it, and I'm fairly new to MadCap Flare. I have recently inherited a rather large help file for a software that my company produces, which allows clients to have specific features. It's fairly obvious how to add sections for them if they have a feature which is specific to them, but if they have parts of the software that do not pertain to them, is there a way to use conditional text to hide a section from only them, without making it conditional to every single other client?

For example I have client A who has requested that sections 2 and 3 be replaced with section 4. The problem with what is shown below is that client A will see all 4 sections, when they should only see 1 and 4. Is there a way I can hide 2 and 3 from them without trying to do a complete overhaul of the entire document where I make all text conditional with the tag of every single client?

<li>1</li>
<li>2</li>
<li>3</li>
<li MadCap:conditions="Clients.A">4</li>

Any help would be appreciated.
Paulie
Sr. Propeller Head
Posts: 140
Joined: Sun Mar 01, 2015 3:01 pm

Re: Using Conditional Tags to Hide Text

Post by Paulie »

Hi there,

It's hard to give an answer without knowing all of the ways that your conditions could be applied. But, as conditions are predominantly used for excluding content, it might be better to reverse your logic and have a 'Not Client A' condition applied to section 2 and 3, rather than a 'Client A' condition applied to section 4. This condition could then be excluded in your client A target, causing the required behaviour.
"In an ideal world, software should be simple, well designed, and completely intuitive to end users. In the real world, good documentation is king."
SteveS
Senior Propellus Maximus
Posts: 2089
Joined: Tue Mar 07, 2006 5:06 pm
Location: Adelaide, far side of the world ( 34°56'0.78\"S 138°46'44.28\"E).
Contact:

Re: Using Conditional Tags to Hide Text

Post by SteveS »

Welcome to the forums :D

Based on the information you have provided, I would set up the customers who require different information with 2 conditions, IncludeForX and ExcludeForX.

You can then (in your example) Apply you IncludeForX on the fourth item and ExcludeForX on items two and three.

I would investigate making the IncludeFor conditions as exclude for all the other customers. If they, too, need a particular element included, adding the IncludeFor condition for them (on a particular element) will override the exclude on that element.

Hope this makes sense (I haven't had coffee yet)...
Last edited by SteveS on Wed Oct 18, 2017 2:28 pm, edited 3 times in total.
Reason: I'm a bit anal about spelling and punctuation, even if I'm wrong...
Image
Steve
Life's too short for bad coffee, bad chocolate, and bad red wine.
BWallace
Jr. Propeller Head
Posts: 2
Joined: Wed Oct 18, 2017 10:38 am

Re: Using Conditional Tags to Hide Text

Post by BWallace »

Ok, I think I'm understanding what you're saying correctly, and doing some extra searches I found this solution, though it may or may not be the most efficient option, so if you happen to know of a better way let me know, but this seems to work. I can set up a new client called NotA, and exclude that client from the printout. If there is a way to do this without creating unnecessary clients like this, I'd appreciate that, but I've tried adding not statements to this in different ways, and it does not really work. I've tried things like "<li MadCap: conditions="not(Cliends.A)"> if that gives a better idea of what I'm trying to do. I also tried looking for statements like a Conditions!="Clients.A" statements and such, to no avail.

<li>1</li>
<li MadCap:conditions="Clients.NotA">2</li>
<li MadCap:conditions="Clients.NotA">3</li>
<li MadCap:conditions="Clients.A">4</li>
Post Reply