Alternate Row Colors in Crystal Report Often you see something like this: Format Section - Color Tab, click on the formula for specifying the background color, and enter: if RecordNumber mod 2 = 1 then Color (233, 233, 233) else crNoColor But that only changes the color on every other RECORD. What if you're grouping or suppressing records??? If you want to change the background color on every other GROUP, or on every other FUNCTION, then you have to do something a little more complicated Add a formula called 'Alternate' to your report. The formula should be (VB syntax): shared alternate_record as boolean alternate_record = not alternate_record formula = alternate_record Then, set the background color formula (as above) to: if {@Alternate} then Color (233, 233, 233) else crNoColor
Created By: amos 4/14/2006 6:25:17 PM Updated: 1/30/2017 8:46:22 AM
|
|