* Occupation icons in Diagrams
- rodit
- Famous
- Posts: 228
- Joined: 02 Feb 2008 02:39
- Family Historian: V7
- Location: Wollongong, New South Wales, Australia
Occupation icons in Diagrams
I use icons in Diagrams to show all sorts of things - Immigration, BMD's, Occupations, etc.
Looking over one family of Miners/Colliers in the Yorkshire mines, I noticed that there was no icon for one who had been a Collier.
The Expression I have always used to generate the required icon is:-
=IsTrue(ContainsText(%INDI.OCCU[1+]%,"miner",STD) or ContainsText(%INDI.OCCU[1+]%,"collier",STD))
It finally dawned on me that his icon was not showing because this was his second listed Occupation. His first was that of electrician. I believe that this is the reason, but have been unable to resolve the problem, even though I have ploughed through the KB and a number of topics.
Perhaps Mike Tate could point me in the right direction.
Thanks in advance
Roger
Looking over one family of Miners/Colliers in the Yorkshire mines, I noticed that there was no icon for one who had been a Collier.
The Expression I have always used to generate the required icon is:-
=IsTrue(ContainsText(%INDI.OCCU[1+]%,"miner",STD) or ContainsText(%INDI.OCCU[1+]%,"collier",STD))
It finally dawned on me that his icon was not showing because this was his second listed Occupation. His first was that of electrician. I believe that this is the reason, but have been unable to resolve the problem, even though I have ploughed through the KB and a number of topics.
Perhaps Mike Tate could point me in the right direction.
Thanks in advance
Roger
Re: Occupation icons in Diagrams
Roger,
From what I understand, you must iterate through all of the possible occupations manually by index, so my guess would be adding additional expressions which refer to %INDI.OCCU[2]%,"miner",STD, %INDI.OCCU[3]%,"miner",STD, etc, in order to capture all possible occupations of a person. I suppose that is what you've tried to do with the [1+] notation, but I've not seen that before...
Related topic - https://www.fhug.org.uk/forum/viewtopic ... 584#p85584
From what I understand, you must iterate through all of the possible occupations manually by index, so my guess would be adding additional expressions which refer to %INDI.OCCU[2]%,"miner",STD, %INDI.OCCU[3]%,"miner",STD, etc, in order to capture all possible occupations of a person. I suppose that is what you've tried to do with the [1+] notation, but I've not seen that before...
Related topic - https://www.fhug.org.uk/forum/viewtopic ... 584#p85584
Sarah Bell – Australia
View my tree on Wikitree
View my tree on Wikitree
Re: Occupation icons in Diagrams
Would making it the preferred occupation and adjusting the expression accordingly work for you? If there is no preferred it defaults to the first so you'd only have to set preferred on the individuals where it wasn't the first.
Edit to add screen shot.
Edit to add screen shot.
- Attachments
-
- Preferred occupation.png (34.3 KiB) Viewed 439 times
Last edited by jelv on 01 Aug 2023 08:21, edited 1 time in total.
John Elvin
- tatewise
- Megastar
- Posts: 27074
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Occupation icons in Diagrams
Roger, the [1+] looping index only works in Text Schemes and nowhere else.
So if you want icons for such Occupations you must use one of the techniques suggested by Sarah and John.
This is one of the scenarios where it might be easier to have a Record Flag for each type of Occupation and apply the icon when the Record Flag is set.
BTW: I have never quite understood why the [1+] looping index only applies to Text Schemes.
So if you want icons for such Occupations you must use one of the techniques suggested by Sarah and John.
This is one of the scenarios where it might be easier to have a Record Flag for each type of Occupation and apply the icon when the Record Flag is set.
BTW: I have never quite understood why the [1+] looping index only applies to Text Schemes.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
- rodit
- Famous
- Posts: 228
- Joined: 02 Feb 2008 02:39
- Family Historian: V7
- Location: Wollongong, New South Wales, Australia
Re: Occupation icons in Diagrams
Thanks to you all. I will take the suggestions on board and see hoe I go.
Roger
Roger
Re: Occupation icons in Diagrams
how would you change the equation to use the Preferred occupation, then? thanks
Re: Occupation icons in Diagrams
Incidently, often the occupation that is most pertinent is not the first one so in the absence of a preferred it would be best if it defaulted to the last (e.g. if the first is "Scholar" from a census).
There's a wish list item asking for a new index option that does that - if this is something you'd like to see added to FH please vote for it.
New data reference index option "preflast"
There's a wish list item asking for a new index option that does that - if this is something you'd like to see added to FH please vote for it.
New data reference index option "preflast"
John Elvin