+ Reply to Thread
Results 1 to 14 of 14

MS Word Mail Merge - insert page break after new data set begins?

  1. #1
    Registered User
    Join Date
    04-22-2010
    Location
    Tallahassee, FL
    MS-Off Ver
    Excel 2007
    Posts
    12

    MS Word Mail Merge - insert page break after new data set begins?

    Hello,

    Any help is greatly appreciated!

    I am trying to create a mail merge that has 6 student progress reports showing on a single printed page. Each progress report has student grade data and a teacher name on it. I would like to have a page break inserted as the teacher names change. This would allow me to print the file and sort by teacher name for easy distribution since the printed pages would be grouped by 'Teacher'.

    I have created a sample data file and sample word file. I have downloaded an add on called 'merge tools' and tried the 'Many to One' feature, but was unable to get it to work properly. I am not familar with code, but I can follow simple cut and paste directions!

    Again, I greatly appreciate your time and effort in assisting me with this project I am working on. This project, if I get it up and running, will help us track our student's progress!
    Attached Files Attached Files

  2. #2
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,726

    Re: MS Word Mail Merge - insert page break after new data set begins?

    See attached. The document uses a Directory merge, which only requires a single set of cells and a two-column page layout, and none of your DOCVARIABLE fields.

    Note: there is an unavoidable gap around all of the grouped cells.
    Attached Files Attached Files
    Cheers,
    Paul Edstein
    [Fmr MS MVP - Word]

  3. #3
    Registered User
    Join Date
    04-22-2010
    Location
    Tallahassee, FL
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: MS Word Mail Merge - insert page break after new data set begins?

    Thank you for your post. However I am trying to recreat this so I have a better understanding. However I am not sure what you mean by: "only requires a single set of cells"

    -Mail Merge - Directory
    -page setup with 2 columns & then I Created template/table
    -Selected source file
    -Inserted my merge fields
    -Finish & Merge - 'Edit Individual Documents'

    The finish product produced 6 tables on a page, looked great, however it did not page break for each new teacher.

    I think I am missing something as I insert my merge fields?

  4. #4
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,726

    Re: MS Word Mail Merge - insert page break after new data set begins?

    The attachment, as returned, has the entire field construction you'll require. Did you examine the field coding and test the merge by re-connecting the document to your own data source & executing the merge? It is rather more complicated than simply inserting the table and mergefields.

  5. #5
    Registered User
    Join Date
    04-22-2010
    Location
    Tallahassee, FL
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: MS Word Mail Merge - insert page break after new data set begins?

    Ok, I see. Field Codes are new to me, and I did find more of your posts along with your reference to a merge tutorial. I was able to add my own source data to the file you posted, but I am having trouble removing a 'cell' that my table is pasted inside? I realize that I don't need that outter cell and I could possibly get more data tables per page without it. When I turn on the field coding I am having trouble viewing all of the code. It looks like some is hidden behind the table, sounds simple but I am having trouble moving the table out of the way!? Not a major issue I was just trying to recreate the document based on what you posted and with the tutorial. It is hard to tell where the data table fits in within the string of code. See picture posted:


    Untitled.jpg

  6. #6
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,726

    Re: MS Word Mail Merge - insert page break after new data set begins?

    The difficulty you'll have viewing the field code is due to its paragraph line spacing being set to 0.7pt - which is required to minimise the inter-table vertical spacing. To view the code more easily you can set the paragraph spacing back to single spacing without upsetting anything else.

  7. #7
    Registered User
    Join Date
    04-22-2010
    Location
    Tallahassee, FL
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: MS Word Mail Merge - insert page break after new data set begins?

    Ok, thanks. In my efforts to recreate this, I am receiving the following errors(see images attached). I have pasted 2 pictures, one showing the code I used and the other showing the preview. The preview looked good, but once I finished the merge I got errors. I recreated using an outer table and then inserting my table that will contain the data. I tried creating this without the outer table, but I could not get the proper formatting - word kept cutting the table off and wrapping it to the next page. I figure the outer table will prevent that formatting issue. Not sure if that is the best way to go or not? I am trying to get 10 per page.

    Again, I appreciate your time.
    FieldCodes.jpgPreview.jpg
    Last edited by MattR; 05-03-2014 at 07:51 PM. Reason: clean-up

  8. #8
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,726

    Re: MS Word Mail Merge - insert page break after new data set begins?

    It's not really apparent from your attachments what's going on with the document. Try the attached.
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    04-22-2010
    Location
    Tallahassee, FL
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: MS Word Mail Merge - insert page break after new data set begins?

    {THAT SHOULD DO IT} Thank you for your help with this. I was using the {QUOTE 12} for page breaks, but I take it that it is easier to adjust the line spacing when using " Ctrl+Enter " (just a guess not really sure!). I adjusted the Before/After spacing to create a slightly larger gab between tables.

    I have enjoyed learning about field codes, as this was completely new for me!

    Thanks again for your time!

    Matt

  10. #10
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,726

    Re: MS Word Mail Merge - insert page break after new data set begins?

    In the latest attachment, I reduced the size of the paragraph break by using a 1pt font there, combined with a 0.2 multiple line spacing. That's a bit different to what I did with the previous version. You could adjust the inter-table spacing by changing either of those parameters.

    You could indeed use {QUOTE 12} to insert page breaks, but I've used a continuous & 'next page' Section break pair so the columns will be more-or-less balanced on pages that don't get filled.

  11. #11
    Registered User
    Join Date
    09-17-2019
    Location
    Phlippines
    MS-Off Ver
    MS Office 2016
    Posts
    2

    Post Re: MS Word Mail Merge - insert page break after new data set begins?

    Hi,

    Can I ask for help please. I was looking for some tuitorial on how to input page break on a mail merge and I found out this thread. This is very helpful and tried to apply it on what I am currently doing. But I encountered error while executing the given sample on my work. Could you please help on this. Thank you in advance for the help.

    Output result should be:

    -Every new System ID(Customer Name) should be in next page.
    ( I am currently doing a one pager report).

    Hope you could help me on this.

    Thank you very much!
    Attached Files Attached Files
    Last edited by JackMock; 09-17-2019 at 11:03 PM. Reason: edit some sentences.

  12. #12
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,726

    Re: MS Word Mail Merge - insert page break after new data set begins?

    You can use Word's Catalogue/Directory Mailmerge facility for this (the terminology depends on the Word version). To see how to do so with any mailmerge data source supported by Word, check out my Microsoft Word Catalogue/Directory Mailmerge Tutorial at:
    http://www.msofficeforums.com/mail-m...-tutorial.html
    or:
    http://www.gmayor.com/Zips/Catalogue%20Mailmerge.zip
    The tutorial covers everything from list creation to the insertion & calculation of values in multi-record tables in letters. Do read the tutorial before trying to use the mailmerge document included with it.

    Depending on what you're trying to achieve, the field coding for this can be complex. However, since the tutorial document includes working field codes for all of its examples, most of the hard work has already been done for you - you should be able to do little more than copy/paste the relevant field codes into your own mailmerge main document, substitute/insert your own field names and adjust the formatting to get the results you desire. For some worked examples, see the attachments to the posts at:
    http://www.msofficeforums.com/mail-m...html#post23345
    http://www.msofficeforums.com/mail-m...html#post30327

    Another option would be to use a DATABASE field in a normal ‘letter’ mailmerge main document and a macro to drive the process. An outline of this approach can be found at: http://answers.microsoft.com/en-us/o...1-1996c14dca5d
    Conversely, if you're using a relational database or, Excel workbook with a separate table with just a single instance of each of the grouping criteria, a DATABASE field in a normal ‘letter’ mailmerge main document could be used without the need for a macro. An outline of this approach can be found at:
    https://answers.microsoft.com/en-us/...f-8642e46fa103
    For some working examples, see:
    http://www.msofficeforums.com/mail-m...-multiple.html
    https://www.excelforum.com/excel-gen...ml#post5110813

    Alternatively, you may want to try one of the Many-to-One Mail Merge add-ins, from:
    Graham Mayor at http://www.gmayor.com/ManyToOne.htm; or
    Doug Robbins at https://onedrive.live.com/?cid=5AEDC...43615E886B!566

  13. #13
    Registered User
    Join Date
    09-17-2019
    Location
    Phlippines
    MS-Off Ver
    MS Office 2016
    Posts
    2

    Re: MS Word Mail Merge - insert page break after new data set begins?

    Thanks a lot for the quick reply . Will try to do it

  14. #14
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: MS Word Mail Merge - insert page break after new data set begins?

    Quote Originally Posted by JackMock View Post
    Thanks a lot for the quick reply . Will try to do it
    Administrative Note:

    Welcome to the forum.

    For future reference, we are happy to help, however whilst you feel your request is similar to this thread, experience has shown that things soon get confusing when answers refer to particular cells/ranges/sheets which are unique to your post and not relevant to the original.

    Please see Forum Rule #4 about hijacking and start a new thread for your query.

    If you are not familiar with how to start a new thread see the FAQ: How to start a new thread
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] MS Word Mail Merge, 3 records per page?
    By H.E. Pennypacker in forum Word Formatting & General
    Replies: 1
    Last Post: 12-31-2012, 10:34 PM
  2. IF Statement in Word Mail Merge Adding Extraneous Empty Page
    By nycstinger in forum Word Formatting & General
    Replies: 0
    Last Post: 09-11-2009, 11:14 AM
  3. Replies: 0
    Last Post: 04-21-2006, 03:40 PM
  4. [SOLVED] Word Mail Merge with Excel as data file
    By HT in forum Excel - New Users/Basics
    Replies: 2
    Last Post: 07-13-2005, 07:05 PM
  5. [SOLVED] Word mail merge with Excel data
    By Bailey in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-30-2005, 06:06 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1