Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
jagannalla
Partner - Specialist III
Partner - Specialist III

TreeView Display

Hi,

- I want to display in sheet in treeview format. I've a 5 groups for each group there is a different FieldNames.

- If i select 1 group i want to display FieldNames of particular group only viceversa for all groups.

Eg:

Group:

A

B

C

D

E

- Now I'll select 'A' in group den i want to display FieldNames of A in list box Otherwise if i select 'B' den i want to display FieldNames of B in another list box.

13 Replies
IAMDV
Master II
Master II

I had looked into the example and I am not sure if you are referring to chart objects, where if you select one chart the other chart minimizes. If this is what you are looking then you need enable Auto Minimize option under "Caption" tab.

I am also attaching a screenshot for your reference. Let me know if you need something else.

Cheers - DVAutoMinimize.png

jagannalla
Partner - Specialist III
Partner - Specialist III
Author

D V - Yes, I want to change the position of objects based on seleciton. I mean if you select A,C,E in the Group Listbox...I want see A,C,E Listboxes in order rather than being random.

- What you understand is correct  D V.

IAMDV
Master II
Master II

Jagannalla - I think you need to use VB Script to get this working. I mean you can't control the obj positioning through expression. However, you can control the positioning through the VB Script. So the idea is to use the logic I gave earlier to activate the objects based the "Group" CheckBox and then you need to get the macro working to position the objects. Here is the sample code to move all the objects on the Sheet. Please edit this code and build a logic around the specific ListBoxes.

Sub ActiveObj_Postioning

Set sh = ActiveDocument.ActiveSheet

For i = 0 to sh.NoOfSheetObjects-1

    set obj = sh.SheetObjects(i)

    set fr = obj.GetFrameDef

    pos = fr.Rect

    pos.Top = pos.Top + 60

    pos.Left = pos.Left + 45

    obj.SetFrameDef fr

Next

End Sub


Good luck!

Cheers - DV

jagannalla
Partner - Specialist III
Partner - Specialist III
Author

D V,

Once again thanks a lot for your macro. But in which action i need to keep this macro. Can you help me little bit more.