Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
davenyrfajutag00
Partner - Contributor III
Partner - Contributor III

Qlik Pixel Perfect - Subtotals and totals color formatting

Good morning,

I'm encountering an issue in my Qlik Pixel Perfect report where I'm unable to apply color formatting to subtotals and totals in a table.

The problem lies in the fact that Qlik does not support the use of the SumRunningSum function within the foreground color expression settings of a cell. As shown in the attached images, there is no available summary function that supports this — only the SUM function is available. However, the SUM function aggregates the total data and does not provide level-based aggregation for subtotals and totals.

I am attempting to use the following expression in the foreground color:

Iif(
(
sumrunningsum([bPuGcB_Level.Fatturato])
-
sumrunningsum([bPGcB_Level.Fatturato Confronto])
)
/
Iif(
sumrunningsum([bPGcB_Level.Fatturato Confronto]) <> 0,
sumrunningsum([bPGcB_Level.Fatturato Confronto])
,sumrunningsum([bPGcB_Level.Fatturato])
)
)
<0,
'Red', 'Black'
)

 

However, when I generate the report, the colors are not applied. It appears this is due to Qlik's limitation in supporting the SumRunningSum function within conditional formatting expressions.

Has anyone encountered a similar issue or found a workaround for applying color formatting to totals and subtotals in Pixel Perfect reports?

Thank you in advance for your help.

 

davenyrfajutag00_2-1752220947353.png

 

 

davenyrfajutag00_1-1752220929520.png

 

davenyrfajutag00_0-1752220897418.png

 

Best regards

1 Reply
Ruggero_Piccoli
Support
Support

Hi,

SumRunningSum functions are available only for the Text property of labels and table cells.

In Foregroun Color property you could try to use a PixelPerfect aggregation formula like:

Iif(
    /* sum of the field Fatturato of current group*/
    [][[bPGcB_Level.LevelKey] == [^.bPGcB_Level.LevelKey]]
        .Sum([bPGcB_Level.Fatturato])
    -
    /* sum of the field Fatturato Confronto of current group */
    [][[bPGcB_Level.LevelKey] == [^.bPGcB_Level.LevelKey]]
        .Sum([bPGcB_Level.'Fatturato Confronto'])
    < 0,
    'Red',          /* if difference is negative */
    'Black'         /* default  color*/

Best Regards,

Ruggero



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.