Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Setting color based on value being selectable ( date range selection/navigation )

I'm drawing a bar chart with date as dimension and sum( {1} Data.Counter ) as expression, to get a full view of item count over time.

img_1.png

I'd like to set the color of currently selected dates, like this

img_2.png

I know I can set color in the properties of the expression

img_3.png

But I can't figure out the if -expression I should use. Does anyone know how to achieve this? What I'm looking for is something like

if ( CurrentDate IN SelectedDates, RGB(0, 0, 0), RGB(255, 255, 255) )

1 Solution

Accepted Solutions
marcus_sommer

You could try something like this:

if(YourDateField, red())

     or maybe

if(Year = getfieldselections(Year), red())

- Marcus

View solution in original post

3 Replies
marcus_sommer

You could try something like this:

if(YourDateField, red())

     or maybe

if(Year = getfieldselections(Year), red())

- Marcus

hic
Former Employee
Former Employee

I would use something like

     If(Count(Date)>0, LightGreen(), LightGrey())

HIC

tresesco
MVP
MVP

Or, may be even like,

If(Date=Date, LightGreen(), LightGrey())


Edit: Well,

Marcus's:  if(YourDateField, red())  is even simpler.