Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

dynamic color of rows 1

Status
Not open for further replies.

yehong

Programmer
Sep 22, 2003
291
US
Hi guys, I have a report in which I am currently displaying dynamic color of rows by this formula:
//@dynamic color
if (recordnumber mod 2) = 1
then
crwhilte
else
crsilver)
It works fine but only if I don't supress duplicate records. But it does not work when I use this formula to supress duplicates:
//@supress
(table1.column1)=previous(table1.column1)

Any ideas how to achieve dynamic coloring in this situation?
 
Create a running total {#cnt} that counts column1 and evaluates using a formula:

onfirstrecord or
{table.column1} <> previous({table.column1})

Reset never.

Then change your color formula to:

if {#cnt} mod 2 = 1
then
crwhite
else
crsilver

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top