| View previous topic :: View next topic |
| Author |
Message |
gcso3 Newbie

Joined: 27 Apr 2006 Posts: 2
|
Posted: Wed Sep 13, 2006 12:13 am Post subject: Blank Lines in Mail Merge |
|
|
| Is there anyway to suppress blank lines in printing envelopes using Mail Merge? |
|
| Back to top |
|
 |
foxcole Super User


Joined: 19 Jan 2006 Posts: 2771 Location: Minneapolis, Minnesota
|
Posted: Wed Sep 13, 2006 4:30 am Post subject: Re: Blank Lines in Mail Merge |
|
|
| gcso3 wrote: | | Is there anyway to suppress blank lines in printing envelopes using Mail Merge? |
I don't know how to do it (yet) because I don't use mail merge, but I do remember seeing this same question posted very recently in this forum... within the past couple of weeks, I think. Try a forum search. Good luck. _________________ Cheers!
---Fox
WinXP Pro SP2, OOo Portable 2.3.1, OOo local 2.4 RC4
New OpenOffice forum: http://user.services.openoffice.org/en/forum/
Manuals: http://documentation.openoffice.org/manuals/index.html |
|
| Back to top |
|
 |
JohnV Administrator

Joined: 07 Mar 2003 Posts: 8995 Location: Lexinton, Kentucky, USA
|
|
| Back to top |
|
 |
james_h Super User


Joined: 05 Nov 2005 Posts: 883
|
Posted: Wed Sep 13, 2006 5:11 pm Post subject: OOo 2 Writer: How to hide empty address lines |
|
|
Important: See following message thread
OpenOffice.org 2 Writer: How to hide empty address lines in a mailmerge (envelope)
Place the text cursor at the beginning of the line to selectively hide.
Insert > Fields > Other...
Click Functions tab
Under Type, select Hidden Paragraph
Under Condition, enter a formula in this form: the field label in the line to selectively blank, an equals sign, then two double quotes. (i. e.: for a Thunderbird address book, you could use theAddress 2="")
Click OK
To verify that the field exists, make sure View > HIdden Paragraphs is checked and that View > Field Names is checked.
To edit the hidden paragraph field, double click it.
Last edited by james_h on Fri Sep 15, 2006 8:25 am; edited 1 time in total |
|
| Back to top |
|
 |
JohnV Administrator

Joined: 07 Mar 2003 Posts: 8995 Location: Lexinton, Kentucky, USA
|
Posted: Thu Sep 14, 2006 7:56 am Post subject: |
|
|
james_h,
If you use the Label Wizard (File > New > Labels) or Envelope Wizard (Insert > Envelope) to create these items and let the wizard insert the fields for various address lines then the address lines will be separated by Line Breaks instead of Paragraph Breaks. Thus a Hidden Paragraph field before, or after, one of these lines will cause the entire address to to hidden on a true condition.
Accordingly, I feel your first step should be something like, "Turn on View > Nonprinting Characters and change any Line Breaks to Paragraph Breaks".
I also think in your Condition step the use of "an equals sign" and then an example of >theAddress 2=""< is confusing. Why not just use >theAddress EQ ""< or Not(theAddress).
Sorry for the critcism but I think you are developing a set of answers to FAQs. This is great, I just think they should be as complete and clear as possible. |
|
| Back to top |
|
 |
james_h Super User


Joined: 05 Nov 2005 Posts: 883
|
Posted: Thu Sep 14, 2006 10:13 pm Post subject: OOo 2 Writer: How to hide empty address lines (correction) |
|
|
Important: See following message thread
On Thu September 14, 2006 JohnV wrote: | Quote: | | Sorry for the critcism but I think you are developing a set of answers to FAQs. This is great, I just think they should be as complete and clear as possible. | Thanks for the comment! I hope this is clearer!
OpenOffice.org 2 Writer: How to hide empty address lines in a mailmerge (envelope)
Turn on View > Nonprinting Characters and change any Line Breaks to Paragraph Breaks
Place the text cursor at the beginning of the line to selectively hide.
Insert > Fields > Other...
Click Functions tab
Under Type, select Hidden Paragraph
Under Condition, enter Fieldname="". (i. e.: if you are using the Thunderbird address book as a data source, you could use Address 2="" to hide the second line of the address if it the Address 2 field is blank.)
Click OK
To verify that the field exists, make sure View > HIdden Paragraphs is checked and that View > Field Names is checked.
To edit the hidden paragraph field, double click it.
Last edited by james_h on Fri Sep 15, 2006 8:26 am; edited 1 time in total |
|
| Back to top |
|
 |
JohnV Administrator

Joined: 07 Mar 2003 Posts: 8995 Location: Lexinton, Kentucky, USA
|
Posted: Fri Sep 15, 2006 6:58 am Post subject: |
|
|
james_h,
The equals operator is written with double equals signs:
Fieldname == ""
I thought perhaps you were trying to indicate this with the "2=" in <Address 2=""> because, as far as I know, OOo can't handle two word field names. You now know why I said "confusing" instead "incorrect". |
|
| Back to top |
|
 |
james_h Super User


Joined: 05 Nov 2005 Posts: 883
|
Posted: Fri Sep 15, 2006 8:15 am Post subject: Thanks for alerting me... I just may be out of luck... |
|
|
Thanks very much for your additional comment. The custom envelope template I used worked for me (even with the single equals sign), but with OpenOffice.org version 2.0.3 it seems not to even if I change to double equals signs. (The second address line is always hidden.) Thanks for alerting me that I need to change my template.
On Fri September 15, 2006 JohnV wrote: | Quote: | | as far as I know, OOo can't handle two word field names |
Unfortunately, Thunderbird address book uses two word field names, so if I can't use them in a logical expression, I just may be out of luck. I will look into this. |
|
| Back to top |
|
 |
acknak Moderator


Joined: 13 Aug 2004 Posts: 4295 Location: ~ 40°N,75°W
|
Posted: Fri Sep 15, 2006 9:16 am Post subject: |
|
|
When I drag a data source column into the condition entry, the field spec is enclosed in square brackets: | Code: | | [Members4.data.Letter Notes]=="" | and that works just fine (using 2.0.4rc1). As far as I can tell, those brackets are optional, unless there is a space in the field name. |
|
| Back to top |
|
 |
james_h Super User


Joined: 05 Nov 2005 Posts: 883
|
Posted: Fri Sep 15, 2006 9:27 am Post subject: [Correction]OOo 2 Writer: How to hide empty address lines |
|
|
[Correction]OpenOffice.org 2 Writer: How to hide empty address lines in a mailmerge (envelope)
Turn on View > Nonprinting Characters and change any Line Breaks to Paragraph Breaks
Place the text cursor at the beginning of the line to selectively hide.
Insert > Fields > Other...
Click Functions tab
Under Type, select Hidden Paragraph
Under Condition, enter Fieldname=="". (NOTE: if you are using the Thunderbird address book as a data source, you need to use square brackets if the field name includes a space (i. e.: [Address 2]=="") to hide the second line of the address if it the Address 2 field is blank.)
Click OK
To verify that the field exists, make sure View > HIdden Paragraphs is checked and that View > Field Names is checked.
To edit the hidden paragraph field, double click it.
Thanks to JohnV and acknak for helping to correct the errors in my original posting. I verified that the instructions work in OOo 2.0.3. |
|
| Back to top |
|
 |
JohnV Administrator

Joined: 07 Mar 2003 Posts: 8995 Location: Lexinton, Kentucky, USA
|
Posted: Fri Sep 15, 2006 10:03 am Post subject: |
|
|
acknak,
Thanks, I didn't know about square brackets. |
|
| Back to top |
|
 |
Straight Shooter General User

Joined: 22 Apr 2006 Posts: 40
|
Posted: Tue Sep 19, 2006 5:09 am Post subject: I have been struggling with this for over an hour |
|
|
Hello,
This is quite frustrating..
May I ask a couple of questions?
First of all, how do you change line breaks to paragraph breaks? I looked.. I can't find a simple answer.
2ndly, after you enter the field name=="" , you CANNOT enter "Okay". It doesn't exist.. It only "Insert" and "Close"..
I don't understand what the problem is,... This is a lot of aggravation for a free product. .. It's just very frustrating when you have deadlines..
Thanks
Jim |
|
| Back to top |
|
 |
acknak Moderator


Joined: 13 Aug 2004 Posts: 4295 Location: ~ 40°N,75°W
|
Posted: Tue Sep 19, 2006 5:54 am Post subject: |
|
|
| Quote: | | ... how do you change line breaks to paragraph breaks? |
Activate regular expression searches: Click "More Options" on Find dialog.
Enter "\n" as both "Search For" and "Replace With".
| Quote: | | ... after you enter the field name=="" , you CANNOT enter "Okay". It doesn't exist.. It only "Inser" and "Close". |
Right. As soon as you click on "Insert", the field is inserted in the document but the dialog stays open. Both the document window and the dialog remain fully operational--you can close the dialog whenever you want after that. Yes it is confusing; that's just the way it works. |
|
| Back to top |
|
 |
Straight Shooter General User

Joined: 22 Apr 2006 Posts: 40
|
Posted: Tue Sep 19, 2006 5:56 am Post subject: I'm sorry.. |
|
|
I'm sorry, but replace with what? A period..? "."
Is that what you're saying?
Thanks
jim |
|
| Back to top |
|
 |
Straight Shooter General User

Joined: 22 Apr 2006 Posts: 40
|
Posted: Tue Sep 19, 2006 6:36 am Post subject: Could someone just straighten out this mess here? |
|
|
| Could someone just break in all down and rewite alll this so someone who doesn't know Ooo well can just do it? |
|
| Back to top |
|
 |
|