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: 
jhupkens
Contributor
Contributor

Qlikview: button- how to create a macro for showing only top 10 values (and switch back to total)

Hi,

I have searched a lot but I cannot find the macro script to show only top 10 values of a table.

The purpose is to create a button and with this button you can easily switch between total values and top 10 values.

Also, in Excel it is possible to 'record' a macro and look at the VBS script. Is this possible in QV as well?

Jesse

Labels (1)
1 Solution

Accepted Solutions
m_woolf
Master II
Master II

No need for a macro.

Create 2 charts, one with all data and one with Top 10.
Set the Conditional Show for each chart to the value of a variable. If the variable is 1, then show the chart with all the data. If the variable is 0, show the chart with the top 10.
Create a button and add actions that will change the variables value from 1 to 0 or 0 to 1.

View solution in original post

2 Replies
m_woolf
Master II
Master II

No need for a macro.

Create 2 charts, one with all data and one with Top 10.
Set the Conditional Show for each chart to the value of a variable. If the variable is 1, then show the chart with all the data. If the variable is 0, show the chart with the top 10.
Create a button and add actions that will change the variables value from 1 to 0 or 0 to 1.

jhupkens
Contributor
Contributor
Author

very easy solution! Thanks for you help.

BR,

Jesse