![]() |
#1
|
|||
|
|||
![]() I'm trying to construct logic where if a merge field is over a certain number of characters, a page break will be inserted. Does anyone have any experience or ideas with this issue? Thanks, Dustin |
#2
|
||||
|
||||
![]()
Hi Dustin,
There is no character count facility, per se. However, you could use code like: {IF«myField»= "?????*" {QUOTE 12}} Where 'myField' is your test mergefield and the count of ? characters is the count of characters required to trigger the page break. Note: The field brace pairs (ie '{ }') for the above example are created via Ctrl-F9 - you can't simply type them or copy & paste them from this message. Likewise, you can't type or copy & paste the chevrons (ie '« »') - they're part of the actual mergefields, which you can insert from the mailmerge toolbar. Also, you can't use this to insert a page break into the mergefield's output - there is no practical way of doing so with mergefield text.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#3
|
|||
|
|||
![]()
Thank you Paul! That worked perfectly! I had tried a similar coding but didn't use the '?' symbol. Thank you for your help and quick response.
Also, is there a list that references what all the {QUOTE ##} fields call for? I knew of {QUOTE 34} meaning ", and now that (QUOTE 12} is a page break, but was curious how many of them there are. Thanks again, Dustin Last edited by deddy; 10-19-2011 at 02:06 PM. |
#4
|
||||
|
||||
![]()
Hi Dustin,
You can use the QUOTE field for any outputting one or more characters from the whole ASCII character set, except for Chr 13 (paragraph break). For example {QUOTE 09} generates a tab, {QUOTE 11} generates a line break, {QUOTE 14} generates a column break and {QUOTE 160} generates a non-breaking space. You might be interested in {QUOTE 68 117 115 116 105 110}
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
Paddywack41 | Word | 1 | 10-06-2011 06:51 AM |
![]() |
BluRay | Mail Merge | 5 | 03-29-2011 01:06 AM |
![]() |
Medievalguy88 | Word | 2 | 01-06-2011 08:19 AM |
*Word 2007 Macro for Character Count | gbartlet | Word | 0 | 07-21-2010 11:12 AM |
Count range cells eliminating merge cells | danbenedek | Excel | 0 | 06-15-2010 12:40 AM |