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.
This time the color expression was incorrect... try with this
if($(vAttend) > 0.95, red(), blue())
I'have tried and it works with color expression in bar chart:
=if($(V_attend)<0.95, Lightblue(), LightRed())
Is it that you're trying to achieve?
Hello,
Hext decimal codes won't work with in the qlikview. You must use the default functions or RGB colors
It is what I am trying to achieve but still isn't working.
Oh, gotcha. I tried the lightblue() and lightred() as instructed above and still could not receive any color. Thanks!
Can you share that sample file your are trying this?
Data:
Dimension: Area_Emp
Measures: =Sum({$<Date_Emp={"$(=Date(Today()-2))"}>} (Actual_Emp / FTE_Emp))
I am subtracting two to show the 3rd because that is the latest work day for this demo.
variable added via "variables" tab
vAttend =Sum({$<Date_Emp={"$(=Date(Today()-2))"}>} (Actual_Emp / FTE_Emp))
Appearance:
Expression: =if ((vAttend) > 0.95, red(), blue())
Try like this?
Expression: =if ($(=vAttend) > 0.95, red(), blue())
If not you have share the sample data as a table it takes time to create a table typing all the relevant field values. Paste your data as a table or upload your sample qvw file please to quickly look into it.
That did not work either. Here is the file. the chart is in the "daily summary" sheet
Is this a Qliksense app?