Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
neha_sri
Creator III
Creator III

Qlikview charts

hi,

I have a scenerio where I have a loading month which contains values of a particular good for 12 months i.e Jan-Dec in a bar chart.Now I want that when I select loading month Jun,I should be able to see Month from Jan to jun in green colour and rest months in red colour, again If I select loading month Mar, I should be able to see in bar chart month jan to mar in green colour and rest months in red colour..

How can I do this in front end

Thanks in anticipation

5 Replies
Anonymous
Not applicable

look at this

neha_sri
Creator III
Creator III
Author

I didnt find any attachment.pls reply soon..

Thanks

Anonymous
Not applicable

should be attached, please check

veidlburkhard
Creator III
Creator III

Hi Neha,

this is a solution without makro. Please see the picture:
TestMatch.jpg

The expression for the color of the bars is:

If(MonthNum <= Match(Month, 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'), RGB(0, 255,0), RGB(255, 0, 0))

Hope this helps

Burkhard

veidlburkhard
Creator III
Creator III

Hi Neha,

last night I had the idea of a much more elegant solution to your problem.

Please, follow these 3 steps:

i) this is your script to use

TestMatchScript.jpg

ii) Add an alternate state to your app, e. g. 'A' and chose this state for  the month listbox where your user will do the selections on the month

TestMatch.jpg

iii) Create a variable and assign this value to it: =Only({A}MonthNum), don't forget the equal sign.

Use this variable in the expression for the color of the bars in your chart.

TestMatch2.jpg

That's it.

Happy qliking

Burkhard