A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Mailing address



 
 
Thread Tools Display Modes
  #1  
Old February 7th, 2009, 04:44 AM posted to microsoft.public.access.gettingstarted
Roger Bell
external usenet poster
 
Posts: 275
Default Mailing address

I have the following text box on a report:

=Trim([titles] & " " & [firstname]) & " " & [lastname] & Chr(13) & Chr(10) &
Trim([unit/flat] & " " & [unit/flat no] & Chr(13) & Chr(10) & "" & ([street
number] & "" & [street prefix] & " " & [street name]) & Chr(13) & Chr(10) &
Trim([suburb] & " " & [state] & " " & [pcode]))

What I would like is when there is no Unit/Flat in the address, then this
line space will close up.

Could someone kindly advise how this can be achieved? Many Thanks
  #2  
Old February 11th, 2009, 02:52 AM posted to microsoft.public.access.gettingstarted
StrayBullet via AccessMonster.com
external usenet poster
 
Posts: 48
Default Mailing address

This should get rid of the extra line:

=Trim([titles] & " " & [firstname]) & " " & [lastname] & Chr(13) & Chr(10) &
Iif(not isnull([unitflat]),Trim([unit/flat] & " " & [unit/flat no]) & Chr(13)
& Chr(10),"") & ([street
number] & "" & [street prefix] & " " & [street name]) & Chr(13) & Chr(10) &
Trim([suburb] & " " & [state] & " " & [pcode]))

Roger Bell wrote:
I have the following text box on a report:

=Trim([titles] & " " & [firstname]) & " " & [lastname] & Chr(13) & Chr(10) &
Trim([unit/flat] & " " & [unit/flat no] & Chr(13) & Chr(10) & "" & ([street
number] & "" & [street prefix] & " " & [street name]) & Chr(13) & Chr(10) &
Trim([suburb] & " " & [state] & " " & [pcode]))

What I would like is when there is no Unit/Flat in the address, then this
line space will close up.

Could someone kindly advise how this can be achieved? Many Thanks


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...arted/200902/1

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 04:56 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.