Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have several hierarchies coming into a list object displayed as tree view.
I have an expression to display the tree structure, which cannot be changed - I cannot use the PATH for some other technical reasons.
How can I just make the only visible hierarchy in my tree structure view, the hierarchy I have selected in my hierarchy name list box ?
attached is the ".qvw" and the hierarchy .qvd.
Any help appreciated !
Please see attached file. I've created two alternative list boxes one using your expression and one using the hierarchy path. When hierarchy name is selected the tree view listbox only displays the visible hierarchy. Hope this works. p.s do check whether the use of nested ifs in your expression can cause performance issues.
regards
sana
Hi Gerry,
Try Hide Excluded flag in Listbox properties
Hope it helps
Regards,
Sergey
cannot use hide exlcuded - due to other technical / display reasons
is there another way to accomplish this ?
Yes. You can create four listboxes and show in conditionally based on what is selected in your other listbox.
For example a condition will be HIERARCHY_NAME='FPA (Dafault)'
etc.
Regards,
Sergey
P.S.: It would be good to know what technical limitation do you have.
Please see attached file. I've created two alternative list boxes one using your expression and one using the hierarchy path. When hierarchy name is selected the tree view listbox only displays the visible hierarchy. Hope this works. p.s do check whether the use of nested ifs in your expression can cause performance issues.
regards
sana
OMG ! Wow ! I think you worked it out ! I need to look at this further.
Let me know where I can send the box of chocolates
but one question: why do you have the 'if' statement repeating.
can you explain your pick(match in English syntax ...
Gerry.
HI Sergey:
My requirements are that I do not know how many hierarchies I will be importing, I needed it to be totally flexible to accomodate an unknown limit. Can't have a static number of list boxes.
Gerry.
The pick match is being used instead of multiple ifs here…..
so in this EXPRESSION:
pick(match(GetSelectedCount(HIERARCHY_NAME),0,1),
hierarchy_tree,
pick(match(HIERARCHY_NAME,GetFieldSelections(HIERARCHY_NAME)),hierarchy_tree))
THE PICK(MATCH is doing something like below:
if GetSelectedCount(HIERARCHY_NAME)=0 then the listbox returns the field hierarchy_tree
and if GetSelectedCount(HIERARCHY_NAME)=0 then it returns listbox for the expression if(HIERARCHY_NAME=GetFieldSelections(HIERARCHY_NAME),hierarchy_tree)
not very sure but if the if statement isn't repeated then the list box appears blank when nothing is selected in hierarchy_name.
so you can't use the path field instead of the expression in the list box?
ok I think I understand this.
I cannot use the hierarchy_tree, as I need some fine control over the hierarchy in being able to detect what levels
have been chosen, hierarchy_tree does not let me do that, but the if does.
Gerry.