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

Format empty linked record

Status
Not open for further replies.

wormx

Programmer
Oct 15, 2004
1
CA
I hope this hasn't been answered already -- I tried searching the message boards and couldn't find it.

I have a table which lists clients and it's linked to another table which lists delivery dates for them. But not all clients have a delivery date:
[Client] [DelDate]
Client1 June12
Client2
Client3 June14
etc

If I change the formatting for the date field (i.e. make the background silver), the empty fields do not get formatted.

What I'm trying to do is alternate the background on successive lines, but whenever there is no date, there is a white space gap. Any ideas?

Here are my formatting formulas:

//in header @Init
whileprintingrecords;
global numbervar groupcount := 0;

//in details @GroupColour
whileprintingrecords;
global numbervar groupcount;

groupcount := groupcount + 1;

if remainder(groupcount,2) = 0 then silver
else white;

//x=2 background formatting formula
{@GroupColour}
 
I assume you want alternate colors in the detail section. If that's the case, then

1. Right clock on the Detail section on the left and click on format section.

2. Click on the color tab and click on the x+2 button and enter the following formula


if remainder(RecordNumber,2) = 0 then
color(231,249,210)
else
nocolor

That's it
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top