Back in Sept I asked about suppressing blank address lines in labels. Thanks to Bernie, Jay and Mike for their help. I apologize for this late reply. As I'm sure often happens, I used a some of each response. The kicker was that the Name line could be one or two lines:

Mr. Doug Hamilton

or

Mr. Oscar Haslonglastname and
Ms. Ophelia Kepthermaidenname

Jay and Bernie's responses gave me a starting point and worked till I ran into the last name issue. Mike's approach using a variable memo gave me the most flexibility. The label is based on a Family table for the address and a People table for the Family's HeadOfHouse and Spouse - Spouse may or may not exist and may have the Family name or a different last name, so the expressions are, uh, interesting.

Thanks again.  See y'all at the conference.

Doug


MikeB wrote:

in RB7, create your label, Place a variable Memo field on it.

Add / Edit the following variables:

Label : TestAddress
 1  : TEXT   : D : vCr = ((char(13))+(char(10)))
2 : TEXT : D : vAddress = (mainname + .vcr + (ifnull(address1,'', (address1 + .vcr))) + (ifnull(address2,'', (address2 + .vcr))) + city + ', ' + statename + (ifnull(ZipCode,'', ' ' + ZipCode)))


associate the variable memo to vAddress.
the above assumes MainName, City, and StateName CANNOT be null.

----- Original Message ----- From: "Bernard Lis" <[EMAIL PROTECTED]>
To: "RBG7-L Mailing List" <[email protected]>
Sent: Sunday, September 18, 2005 9:45 AM
Subject: [RBG7-L] - Re: Supressing blank lines in labels


Doug,

Locate ln3 and ln4 on your label
create the var csz = (city + ',' & state)
cusad2 is the 2nd address line in your customer table (which may be null)

ln3 = (ifeq(cusad2,null,.csz,cusad2))
ln4 = (ifeq(cusad2,null,' ',.csz))

Bernie Lis
----- Original Message ----- From: "Doug Hamilton" <[EMAIL PROTECTED]>
To: "RBG7-L Mailing List" <[email protected]>
Sent: Saturday, September 17, 2005 11:50 PM
Subject: [RBG7-L] - Supressing blank lines in labels


I want to supress blank lines in labels - typically AddrLine2 is null and would like to move the City/State/Zip line up when that is the case. R:Base Help and FTE 11/03 have solutions using code and Mike B posted a stored procedure in Feb 04. But I thought since then I'd seen a posting about feature in Labels that would automatically close blank lines but can't recall it or find an example in ConComp.

I'd apreciate any help.

Tnx, Doug

Reply via email to