The include/exclude function of conditions is blurred

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
Tom
Propeller Head
Posts: 46
Joined: Fri Aug 11, 2006 6:39 am

The include/exclude function of conditions is blurred

Post by Tom »

Hi,
I have 4 versions of a software-application. Each with a different name.
So I made 4 conditions: Va (to exclude version A), Vb (to exclude version B) etc.

Everywhere Ithe original name of the application in the helpfile is used, I want to change it to a contionional string, so I can in the target show the right version-name. For version B, I exclude the conditions Va, Vc and Vd to exclude the names. The string is like this:

<MadCap:conditionalText MadCap:conditions="Primary.F_L,Primary.F_A,Primary.F_B">Unit 4 Multivers</MadCap:conditionalText> <![CDATA[ ]]><MadCap:conditionalText MadCap:conditions="Primary.F_A,Primary.F_B,Primary.F_S">Unit 4 Multivers Lite</MadCap:conditionalText> <![CDATA[ ]]><MadCap:conditionalText MadCap:conditions="Primary.F_L,Primary.F_A,Primary.F_S">Unit 4 Multivers Basic</MadCap:conditionalText> <![CDATA[ ]]><MadCap:conditionalText MadCap:conditions="Primary.F_L,Primary.F_B,Primary.F_S">Unit 4 Accounting</MadCap:conditionalText> <![CDATA[ ]]>

Next I tried to find and replace in the scource-code the name of the application (Unit 4 Multivers) for the string above. That didn’t work because the search-program scans the text of a topic more than one time en finds ‘Unit 4 Multivers’ again in the new condition-string.

I changed in the conditional string the words ‘Unit 4 Multivers’ for ‘U4M’ so that 'Replace' should work.
But than it turned out that the conditions worked the other way around. Excluding (for version B) the conditions ‘Va, Vc and Vd’, made that nothing was visible. But excluding condition Vb turned out to work more or less better in showing at some places the right name. So is seems to me that the include/exclude function of the conditions is reversed when you set more than one condition in one text-line. :(

So, apart from the other known difficulties with the ‘Find and Replace’ in finding word-groups (that is e.g. not finding the word-group when in the code it is divided at the end of a line), I am left with another one. Who knows how to proceed? Any tips or tricks????? :D
By the way I am talking about more than 1100 replacements in more than 1000 topics in the helpfile, so some kind of working automation is quite welcome.

Thanks in advance,
Tom
i-tietz
Propellus Maximus
Posts: 1219
Joined: Wed Oct 24, 2007 4:13 am
Location: Fürth, Germany

Re: The include/exclude function of conditions is blurred

Post by i-tietz »

Tom wrote:Hi,
I have 4 versions of a software-application. Each with a different name.
So I made 4 conditions: Va (to exclude version A), Vb (to exclude version B) etc.

Everywhere Ithe original name of the application in the helpfile is used, I want to change it to a contionional string, so I can in the target show the right version-name. For version B, I exclude the conditions Va, Vc and Vd to exclude the names. The string is like this:

<MadCap:conditionalText MadCap:conditions="Primary.F_L,Primary.F_A,Primary.F_B">Unit 4 Multivers</MadCap:conditionalText> <![CDATA[ ]]><MadCap:conditionalText MadCap:conditions="Primary.F_A,Primary.F_B,Primary.F_S">Unit 4 Multivers Lite</MadCap:conditionalText> <![CDATA[ ]]><MadCap:conditionalText MadCap:conditions="Primary.F_L,Primary.F_A,Primary.F_S">Unit 4 Multivers Basic</MadCap:conditionalText> <![CDATA[ ]]><MadCap:conditionalText MadCap:conditions="Primary.F_L,Primary.F_B,Primary.F_S">Unit 4 Accounting</MadCap:conditionalText> <![CDATA[ ]]>
I don't quite understand the problem:
  • Why would you want to EXCLUDE a few things in a version? Could you give me an example?
  • In the source code you use the conditions F_A, F_B, F_L and F_S, above that you mention Va, Vb, Vc, Vd ... which ones are the correlating ones?
  • Which version of Unit 4 Multivers equals which condition?
The results I think you're going to get with the above source code are:
Condition F_S => Unit 4 Multivers Lite, Unit 4 Multivers Basic and Unit 4 Accounting
Condition F_L => Unit 4 Multivers, Unit 4 Multivers Basic and Unit 4 Accounting
Condition F_B => Unit 4 Multivers, Unit 4 Multivers Lite and Unit 4 Accounting
Condition F_A => Unit 4 Multivers, Unit 4 Multivers Lite and Unit 4 Multivers Basic
Is that not what you expect?
Tom wrote:Next I tried to find and replace in the scource-code the name of the application (Unit 4 Multivers) for the string above. That didn’t work because the search-program scans the text of a topic more than one time en finds ‘Unit 4 Multivers’ again in the new condition-string.
In that case I might be able to help you: All you have to do is search the source code for the string ">Unit 4 Multivers</" instead of "Unit 4 Multivers".
Tom
Propeller Head
Posts: 46
Joined: Fri Aug 11, 2006 6:39 am

Re: The include/exclude function of conditions is blurred

Post by Tom »

Hi I-tietz,

What I want is to do the following: I have four versions of an application, with the following names:
Unit 4 Multivers;
Unit 4 Multivers Lite;
Unit 4 Multivers Basic;
Unit 4 Accounting.
I have a helpfile written for the original application with the name Unit 4 Multivers. The other versions (Lite, Basic and Accounting) have different parts of functionality stemming from Unit 4 Multivers. So in the helpfile and documentation there are sentences like (sorry it is in Dutch):
“Het gebruik van de online-helpfunctie in Unit 4 Multivers

Unit 4 Multivers beschikt over een elektronisch helpbestand dat u kunt
openen met <F1>, of vanuit het menu ‘Help’."


So for Unit 4 Multivers Lite, the same sentence should be:
“Het gebruik van de online-helpfunctie in Unit 4 Multivers Lite

Unit 4 Multivers Lite beschikt over een elektronisch helpbestand dat u kunt
openen met <F1>, of vanuit het menu ‘Help’."


Or for Unit 4 Accounting:
“Het gebruik van de online-helpfunctie in Unit 4 Accounting

Unit 4 Accounting beschikt over een elektronisch helpbestand dat u kunt
openen met <F1>, of vanuit het menu ‘Help’."


For images (that differ per version) I used (in RoboHelp) the conditions F_S, F_L, F_B and F_A. In the build (target) for a version I just had to exclude/use three of the four conditions, just to include only the right image for the version. That worked fine and it also works all right in Flair.

I thought it would also work with the following text: "Unit 4 Multivers Unit 4 Multivers Lite Unit 4 Multivers Basic Unit 4 Accounting", giving each part of the text the appropriate three conditions. So for the name “Unit 4 Accounting” I use the conditions F_S, F_L and F_B, and for "Unit 4 Multivers Basic" I use F_S, F_L and F_A.
And I still think it should work, at least it works for the images. But when I try to use it as described above, it appears that the conditions work the other way around. When I use the conditions regularly everything is left blank.
To show only the name Unit 4 Multivers Lite, I will have to select ‘F_L’. Then the correct name appears. The other point is however, that Flair is in this situation absolutely inconsequent with the conditions. At some places it works, but in quite a few instances it only works with the first name (Unit 4 Multivers) and with the other names, it is left blank. Or it doesn’t work at all and it is always blank whatever the condition.
So I am afraid that just before 'Release time' for the next version of the application, I wil have to copy the helpfile four times and chanching the name with 'Find and Replace'.

In this respect, thank you for the replacement tip ">Unit 4 Multivers</”. Do you also have a suggestion for the not found word-groups (like Unit 4 Multivers) that are divided over two lines? Or when you have a word-group with two or more spaces between the words (mistakes made in history)?

Would be great.
Tom
Last edited by Tom on Wed Jun 04, 2008 6:30 am, edited 1 time in total.
RamonS
Senior Propellus Maximus
Posts: 4293
Joined: Thu Feb 02, 2006 9:29 am
Location: The Electric City

Re: The include/exclude function of conditions is blurred

Post by RamonS »

Tom wrote:Or when you have a word-group with two or more spaces between the words (mistakes made in history)?
That would only apply to non-breakable spaces as there is no way in Flare to have two regular spaces next to each other. You could search the source for double/triple/n-tuple occurrences of non-breakable spaces.
i-tietz
Propellus Maximus
Posts: 1219
Joined: Wed Oct 24, 2007 4:13 am
Location: Fürth, Germany

Re: The include/exclude function of conditions is blurred

Post by i-tietz »

This is how conditions in Flare work:
If you assign ONE condition to an image or a text it is displayed if you INCLUDE that condition - if the object has more conditions: they don't matter. "Excludes" don't work on that object.

The syntax I use for the follwing example is NOT a valid Flare syntax:
The element "<F_A>" says that this is where the condition "F_A" STARTS
The element "</F_A>" says that this is where the condition "F_A" ENDS

Your phrase should look like this:
This stands for dutch dummy text with "Unit 4<F_B><F_S><F_L> Multivers</F_B></F_S></F_L><F_A> Accounting</F_A><F_L> Lite</F_L><F_B> Basic</F_B>".
Means:
  • "Multivers" comes in with including "F_B" or "F_S" or "F_L" (not for F_A, because "Accounting" is supposed to takes its place).
  • "Accounting" comes in with including "F_A".
  • "Lite" comes in with including "F_L".
  • "Basic" comes in with including "F_B".
The phrase looks like this if you include "F_B" - no matter if you exclude all the others: This stands for dutch dummy text with "Unit 4 Multivers Basic".
"Accounting" and "Lite" are left out, because they don't have the condition "F_B".
The phrase looks like this if you include "F_A" - no matter if you exclude all the others: This stands for dutch dummy text with "Unit 4 Accounting".
"Multivers", "Lite" and "Basic" are left out, because they don't have the condition "F_A".
Last edited by i-tietz on Fri Jun 06, 2008 5:12 am, edited 1 time in total.
Tom
Propeller Head
Posts: 46
Joined: Fri Aug 11, 2006 6:39 am

Re: The include/exclude function of conditions is blurred

Post by Tom »

I-tietz,

Thanx. I didn't recognize the Include option in Flair. It works.

Tom
bbuchko
Propeller Head
Posts: 59
Joined: Wed Jul 02, 2008 1:32 pm
Location: Raleigh, NC
Contact:

Re: The include/exclude function of conditions is blurred

Post by bbuchko »

Ahh thanks, this thread helped.

I was trying to create targets for two different sets of conditions: customer and role. So, for example, I had Company X, Y, Z and Role A, B, C. So, I'd want to create targets XA, XB, XC, YA, YB, YC, and ZA, ZB, ZC.

I thought I had to include the two conditions and exclude the rest. But, I didn't realize include overrode exclude, and I was about to tear my hair out. After reading this thread, I realized I just have to exclude and not mark any for include. Now, it works like a charm. Thanks!
Bob Buchko
Technical Communicator
Corporate Trainer
Flare Noob
Post Reply