Discussion Board for collaboration related to QlikView App Development.
I'm trying to shade every other row in a pivot table simply based on being the odd or even row number. In other words rows 1,3,5,6,9,etc. would be a color and 2,4,6,8,10,etc. would be another color.
I've tried to write code on the background color of the field using rowno() and count() but no success.
Any suggestions would be extremely helpful.
In a straight table it is a setting, but that doesn't work for a pivot table. However, you can set the background color on dimensions and expressions.
Dimension: click on the plus-sign in front of the dimension and double-click on the Background Color option.
Expression: click on the plus-sign in front of the dimension and click on the Background Color option. There is a Definition window on the right now.
Add the following expression to all the Background Color fields (dimensions and expressions):
If you don't like the color, you can use a lot of other standard colors (search 'color' in the help) or use RGB(230,230,230) for lighter grey for instance.
Gud example is given by Mark. There is also a feature called 'ColorMix', see help. It is used to set colors for text, or background. More detail is available in manual on ColorMix.
To be able to do that, you need an identifier for field product.
That way you can replace the 'even(RowNo())' part with something that identifies each product.
Have you tried the Color Mix Wizard?
I searched for colormix in Help. I'm still not sure how to start/access the colormix wizard from the instructions below:
With the Colormix Wizard, opened from the File menu in the Edit Expression dialog, it is possible to create a colormix expression, i.e. an expression that calculates a dynamic color from a given measure.
Can you give me more specific instructions to access the colormix wizard?