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 dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Shading Every Other Line

Status
Not open for further replies.

TEM3

Technical User
Dec 6, 2004
324
US
Crystal Reports 11:

Suggestions please for shading every other line (row) in the detail section listing of a report......
 
Conditional format of the background colour in the details section.

if recordnumber mod 2 = 0 then
crgreen
else
crblue
 
From the report Canvas, right click on the detail secvtion on the left side of the canvas and click on Format Section.
Click on the Color tab and then click on the X+2 next to the background color and enter the following formula

Code:
if remainder(RecordNumber,2) = 0 then
//Pale Green like the old greenbar reports
    color(231,255,210)
else
    nocolor

 
The light green looks great on the screen, but hardly shows on a b&w printout. I take it the three numbers are red/yellow/green?? crgray is a little too dark. What would be a lighter gray (which numbers should I play with)?
 
No, the numbers are for red/green/blue. Anyway try color(230,230,230) for a pale gray
 
You can also just select a lighter color, such as:

if recordnumber mod 2 = 0 then
cryellow

To use the standard RGB model KSKID describes, you can test custom colors by selecting the color for any object and select custom. As you move around, note that the RGB numbers are on the right side.

-k


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top