Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Lee_Matthews
Former Employee
Former Employee

Cyclic Dimension in Sense

I have been working on a way to do cyclic dimensions in Qlik Sense. The extension to allow this (and an example) is attached.

However I have an API question that I hope someone can help with. In the extension code I have defined a configuration item called lbltxt which should allow the user to enter the left hand label text, or to set it as blank. However while the field appears in the config items, I dont seem to be able to reference the value when rendering the extension. It just comes up as undefined, so I have hard coded the label for the moment.

If someone familiar with the extension API could spot what I have done wrong that would be great.

Note that the same concept could be used for conditional show of measures or dimensions - assuming you can write the necessary IF() logic and that you want to conditionally choose one item from a list based on the selection in the OptionList.

SelectBreed.png

Note that this is just a hack of the existing Horizontal list box extension that was provided as an example with Qlik Sense, so i cant take much credit. I have reformatted it to be single selection only and to be more slimline so it looks like it is 'attached' to a specific chart. You could equally use it to change the focus of the whole page to a different dimension, as opposed to a single chart. In that case just position it so that it doesn't look like it relates to a single chart and maybe add a title to the field rather than a left hand label.

14 Replies
Lee_Matthews
Former Employee
Former Employee
Author

Hi Alejandro

I have not been able to find any function in the API that does a sort. I guess i could do it by putting the text into a javascript array first, then sorting, then looping through after that. If I get time I might change it to take that approach.

sakamsureshbabu
Creator
Creator

i want to study /.................................

kavicsgym
Creator
Creator

Thank you guys, very helpful 🙂

andrejfreitas
Partner - Creator
Partner - Creator

Hello Lee,

Thanks for sharing. Is there any way to hide or modify the text "Select Option:"?. I've changed inside of the script the text but it did not work. I believe I need to re-compile it,how can I do that on windows? Thanks in advance for your help Mattews.

Lee_Matthews
Former Employee
Former Employee
Author

Untitled.png

Hi

See the attached image. All you should need to do is update the text in the "Prefix Field "

I have made some changes to the code recently, to force it to select a default value if none is selected. I hav eattached the latest code to the posting.