Go to the chart properties, Layout tab, and set in the Show, Conditional dialog the following expression in each chart, changing the value in the right as required.
GetFieldSelections(FieldNameHere) = 'A'
GetFieldSelections() will return the value or values selected in a field. That will return true if the value (and only that value) is selected in the listbox or any other object, and show the chart. When any other value is selected, the chart will be hidden.
Hope that helps.
This code worked.
But now i am facing one more problem,
since it is a list box , when i select A , it shows up the graph but filters the whole dashboard with 'A' .
I think this is happening due to association.
I was hoping to just change these graphs based on the selections in the list box but rest of my boxes should remain
Is there a way to do this or should i use something else instead of list box.
Glad to be helpful.
There are several approaches to that. Probably the most simple is going to the script and load only that field with a different name (in the listbox you can always change the label that is displayed in the dashboard). Then use this second field in the GetFieldSelections() instead of the previous. Since the name of this second field is different, and not related, it will not affect to your charts other than the how / hide property.
You can get that using variables instead of fields, but only in the case that one and only one chart is visible at a time.
Both of them are in the application attached.
There is a third approach that uses set analysis in the expressions. But since there are a lot of charts, and more information in the dashboard, I'd rather use one of the previous.
Hope that helps.
qcomShowHideListboxVariable.qvw 165.5 K