Skip to Content

changing the color of a row in Crosstab of crystal report

Dec 05, 2017 at 11:16 PM


avatar image
Former Member

I have designed crystal report which contains a Crosstab in it and works fine. one of the fields is Time. I want to the whole row color font be changed for the Max Hour which I pass to the report . I can change just the color of the MaxHour Cell but the whole Row. like the following:

the Code is :

if(CurrentFieldValue={?MaxHour}) then



I have set it when I right click of the Time filed, format Object, and then Font. what should I do for changing the color of the whole row of Max Time?

Thank you

crosstab.jpg (177.0 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
Abhilash Kumar
Dec 06, 2017 at 09:06 AM

Hi Nooshin,

Right-click one of the summary cells > Format field > Font tab > Click the formula button beside Color and use this code:

if GridLabelAt("Row Field", CurrentRowIndex) = {?MaxHour} then crTeal else crMaroon

Replace "Row Field" with the field you've used as the Crosstab Row. The field should be enclosed in double-quotes like the way I have above.


10 |10000 characters needed characters left characters exceeded