1 Reply Latest reply: Apr 7, 2015 3:02 AM by Aiham Azmeh RSS

    Conditionally show accordion items in Sense?

      Hi Everyone,


      I'm working on a new extension for a custom visualization, and I can't find anything on this in the documentation. Is there a way to conditionally show items on the accordion panel during editing? For example, in a standard visualization, if you go into Appearance>Colors and Legend>Colors, and toggle it to "Custom", new items appear underneath. Then if you pick another item in the dropdown, more options appear.. I want to do the same thing, basically. I would ideally have a dropdown that conditionally exposes either a text box for expression entry, or a color picker. I already know about accessing the values of each item, so once I get it set up I already have the rest of the code in place.


      Let me know if you have any solutions!



        • Re: Conditionally show accordion items in Sense?
          Aiham Azmeh

          Hi Samuel,


          You should have a look at Toolbar extension example (shipped with QlikSense); in the code you can see a method called show :

          fixed : {

               ref : "field.fixed",

               label : "Use field",

               type : "string",

               defaultValue : "",

               show : function(data) {

                    return data.field && data.field.show && !data.field.list;



          ...and I think you can use it for solving your problem.