Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey everyone,
Making a simple bar chart here and trying to get my colors by expression to work. They are still all the same color. Here is my example data.
I am trying to get the table to show the percentage of employees every day based on Area_Emp.
So first I need to get Actual_Emp/FTE_Emp to get percentage, then make that either blue if below .95% or red if over .95%.
Here is the expression I am using.
Created a variable vAttend =Sum({$<Date_Emp={"$(=Date(Today()-3))"}>} (Actual_Emp / FTE_Emp))
Color expression in bar graph
if (sum(vAttend) < 0.95, '#f93f17', '#f93f17')
Currently they are all red.
The app you sent is working correctly. I have in my app the exact info and it is just red. I could re-attach a new file if needed.
Hi Vishwarath,
This might sound silly but, how are you trying to open th Qvf file.
You are Pasting it to Documents folder Right?
%Userdata%\Documents\Qlik\Sense\Apps
Regards,
Pankaj
Because it's working
Sure, go ahead
thanks
This time the color expression was incorrect... try with this
if($(vAttend) > 0.95, red(), blue())
Oh ok. Got it now. Thanks Pankaj.
It works at my end too. Just followed Sunny's message of removing "=" from the varible definition.
Ok, so I got that working yesterday, and today when I updated the data, it changed back to solid colors. Any idea what's going on?
Are you defining your vAttend in the script?