Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, I'm new to Qlik Sense and can't figure out the right code to display the get selected items on the div or front end view of a extension.
Below is the code that I'm using. (I'm using Extension for Qlik Sense desktop)
I can get the selected value with this code and display it on the browser console.
I have searched and have not find one of any documentation or examples of displaying the selected value on a Qlik Sense Extensions. I have some requirements regarding how the selected fields should look. Below is the sample selected fields should look when a field is locked the object will go orange.
Can anybody help me with the right code syntax?
Hi @jenriquez
I did shared the extension above, I am attaching it again to this reply.
Hi @jenriquez
I can share with you how to pass the front-end UI's current selections to an extension, as long as the extension has a property to receive these values.
I will be using the QlikSense function GetCurrentSelections - chart function
I attached the extension ShowSelections (zipped) to illustrate the code; its code is very similar to yours with the difference of implementing a property: My current selections, when you assign the function GetCurrentSelections(), the current selections are found in the extension script variable: layout.myproperties.myCurrentSelections; as shown
The QlikSense UI used is shown next:
The corresponding output at the DevTools console:
Another option:
You may also implement QlikSense API calls, but I do not have experience implementing extensions' consuming them, so, if you manage to use QS API please share with me !!!! here the link: Get the current selections
hth
Hi @jenriquez
I forgot to attach the extension !!!
can you share your extension here? thanks in advance.
Thank you 😊
Hi @jenriquez
I did shared the extension above, I am attaching it again to this reply.
Thanks for your help, much appreciated. I used your code on how to display the selected fields on HTML code.
below is my code.