locked
MS Word Letter Merge with a table and multiple rows RRS feed

All replies

  • Try Graham Mayor's add-in http://www.gmayor.com/ManyToOne.htm

    Regards, Hans Vogelaar (http://www.eileenslounge.com)

    Monday, January 9, 2017 9:31 PM
  • 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://windowssecrets.com/forums/showthread.php/154370-Microsoft-Word-Catalogue-Directory-Mailmerge-Tutorial
    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.
     
    The field coding for this is 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-merge/9180-mail-merge-duplicate-names-but-different-dollar.html#post23345
    http://www.msofficeforums.com/mail-merge/11436-access-word-creating-list-multiple-records.html#post30327
    http://windowssecrets.com/forums/showthread.php/157725-Word-2010-Merge-from-excel-into-Table-Directory?p=928391&viewfull=1#post928391
     
    Another option would be to use a DATABASE field in a normal ‘letter’ mailmerge main document and a macro to drive the process. An example of this approach can be found at: http://answers.microsoft.com/en-us/office/forum/office_2010-word/many-to-one-email-merge-using-tables/8bce1798-fbe8-41f9-a121-1996c14dca5d
    The DATABASE field can even be used without recourse to a mailmerge. An example of such usage can be found at: http://www.msofficeforums.com/mail-merge/21847-mail-merge-into-different-coloumns.html#post67097
     
    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 (as per Hans' link); or
    Doug Robbins at http://bit.ly/1hduSCB
     
    In addition to a 'Many to One' merge, the latter handles:
    • Merge with Charts
    • Duplex Merge
    • Merge with FormFields
    • Merge with Attachments
    • Merge to Individual Documents
    • Merge, Print and Staple

    Cheers
    Paul Edstein
    [MS MVP - Word]

    Monday, January 9, 2017 9:52 PM
  • Hi vsla,

    From the description of thread we can see that you want use User Interface of Word Application to solve your issue.

    this forum only handles the issue regarding word object model.

    so for better response and better solution for your issue I move this thread to Word it pro discussion forum.

    The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction with us. Thank you for your understanding.

    Regards

    Deepak


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Tuesday, January 10, 2017 2:38 AM
  • Deepak,

    What is the point of moving the thread to a different forum when the chances of getting a better answer is negligible??? The solutions suggested are not limited to Word's User Interface - which is quite unable to facilitate a solution on its own.


    Cheers
    Paul Edstein
    [MS MVP - Word]

    Tuesday, January 10, 2017 8:33 AM
  • Hi macropod,

    Actually we have a different teams to handle User interface related issue.

    so when it looks like user is using User Interface then we need to discuss with that teams and if they agree we have to move it to that teams.

    it is not related with any of the replies that op get on this post.

    it's our internal process that we have to follow.

    Thanks for your understanding.

    Regards

    Deepak


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Tuesday, January 10, 2017 10:13 AM
  • I like the thought of trying Gram Mayor's solution. I downloaded it and installed it, but it wants an MS Excel Spreadsheet as it's datasource. I want to access a SQL Server View.

    I suppose it's not overly complex to write the code, but it's not explained anywhere very well.

    is there not a simple solution ?

    I'm looking to output to letters, too, not to an email. Surely folks have done this sort of thing through the years.


    John

    Tuesday, January 10, 2017 4:30 PM
  • > is there not a simple solution ?

    No, it's complicated, since Word has no built-in support for this.

    The tutorial by Paul (macropod) will work with any data source, including Access or SQL Server.


    Regards, Hans Vogelaar (http://www.eileenslounge.com)

    Tuesday, January 10, 2017 5:31 PM
  • As I said, though, this is NOT an Interface matter... The desired outcome cannot be achieved through the User Interface alone. It requires programming - either: field coding; VBA coding; or both.

    Cheers
    Paul Edstein
    [MS MVP - Word]

    Tuesday, January 10, 2017 9:32 PM
  • Thank you, Paul. Yep. I can see that it does. I'm starting to get it...(a little)... of course I want the results in a table, so I have to push the envelope now in that direction.

    Thank you for the putting the document together, it helps although I was not able to see the actual coding in the "Mailmerge Main Document.doc" document other than the words: If you haven't read the tutorial document, please do so before using this document : ) 


    John

    Wednesday, January 11, 2017 4:41 PM
  • I was not able to see the actual coding in the "Mailmerge Main Document.doc" document other than the words: If you haven't read the tutorial document, please do so before using this document : ) 


    John

    There is no field coding in the "Mailmerge Main Document.doc" file - it's all in the tutorial document, ready to be copied from there into that document. Please read the tutorial's Introduction, especially the topics 'Viewing The Fields' and 'Using the Sample Data File & Mailmerge Main Document'.

    Cheers
    Paul Edstein
    [MS MVP - Word]

    Thursday, January 12, 2017 5:59 AM