Background color in detail section per line 
Author Message
 Background color in detail section per line

How does one get the color in the detail section to alternate between
lines?

I have tried this sample in the color section of the detail section:

if remainder(recordnumber,2) = 0 then silver else nocolor

But this does not work if you are also conditionally supressing lines,
for example, if stock count is 0. You end up with some lines the same
color together, which looks terribly amateur.



Tue, 24 May 2005 10:49:27 GMT  
 Background color in detail section per line
You might try inserting a formula into the detail section.  In the formula,
create a variable.  Use a variation of the condition formula you used in the
suppression, to increment the variable value.  Then, change the color based
on whether the variable is odd or even.

Bob Holmes


Quote:
> How does one get the color in the detail section to alternate between
> lines?

> I have tried this sample in the color section of the detail section:

> if remainder(recordnumber,2) = 0 then silver else nocolor

> But this does not work if you are also conditionally supressing lines,
> for example, if stock count is 0. You end up with some lines the same
> color together, which looks terribly amateur.



Tue, 24 May 2005 22:48:13 GMT  
 Background color in detail section per line
Thanks Bob. If anyone is interested, this is what worked:

--In the background color tab of the color tab of the details section:

whileprintingrecords;
numbervar thisrow;
if trim({TEMPStockList.StockCount}) <> "0" then thisrow := thisrow + 1;
if remainder(thisrow,2) = 0 then silver else nocolor;

--In the suppress tab of the common tab of the details section:

trim({TEMPStockList.StockCount}) = "0"



Fri, 27 May 2005 05:19:10 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. More than 1 record per line in the details section

2. Master-Detail with 2 seperate detail sections per master record, CR.NET

3. How to create Terminal/DOS box, (with background colors per character)

4. How to create Terminal/DOS-box windows (background color definable per character)

5. line numbers in detail section od report

6. Unncessary blank lines in detail section.

7. Detail background color

8. Is it possible to Change background color of individual Listview lines

9. How to make (DB)ListBox show 2 fields per line (1 line = 1 record)

10. How to make (DB)ListBox show 2 fields per line (1 line = 1 record)

11. ? Text Box: multi line; fixed length per line

12. How to make (DB)ListBox show 2 fields per line (1 line = 1 record)

 

 
Powered by phpBB® Forum Software