Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Not applicable

COLOURS WITH CONDITIONS

good morning, My name's Genny and I work in VR46 the Valentino Rossi's company, I have a problem with the colors on Qlik view and I would like to know if and how I could solve it.
When assigning the background color to a dimension, I use the following routine

=IF ([name dimension]=1,GREEN())

This routine is perfect if I filter the dimension with value = 1 but it is not working without filter. without the  filter, the color (green) doesn't appear.

Can I ALWAYS have a colored dimension (i.e. Green) (even if I haven't filter) ?

thanks!!!!!

Tags (1)
1 Solution

Accepted Solutions
fred_s
Contributor III

Re: COLOURS WITH CONDITIONS

Hi,

You could try to add an else, like

=IF ([name dimension]=1,GREEN(),RED())

See attchment

Fred

8 Replies
MVP
MVP

Re: COLOURS WITH CONDITIONS

It should work fine without condition as well. Could you share a sample that shows the issue?

Not applicable

Re: COLOURS WITH CONDITIONS

Hi Genni,

It should without if condition as well.

Try

= RGB(0,255,0)

Thanks!

MVP
MVP

Re: COLOURS WITH CONDITIONS

Hi,

Do you have that dimension declared in Dimension tab?  If not try using

=IF (Max([name dimension])=1,GREEN())


If not working attach sample file.


Regards,

Jagan.

maleksafa
Valued Contributor

Re: COLOURS WITH CONDITIONS

you can simply put in the background color only the expression =Green() or use RGB() colors, without any if conditions.

Not applicable

Re: COLOURS WITH CONDITIONS

I tried ... nothing to do  

as soon as I can, I send an example thanks

fred_s
Contributor III

Re: COLOURS WITH CONDITIONS

Hi,

You could try to add an else, like

=IF ([name dimension]=1,GREEN(),RED())

See attchment

Fred

Not applicable

Re: COLOURS WITH CONDITIONS

perfect !!!! With the "else" is ok!!!!!

THANKS!!!!

However, for multiple conditions which is the syntax in qlik?

If I have many "IF conditions" (and then many colours)?


fred_s
Contributor III

Re: COLOURS WITH CONDITIONS

Hi Genni,

You can use nested IF:

=IF ([name dimension]=1,GREEN(),

      IF([name dimension]=2,YELLOW(),

      RED()

      )

)

Community Browser