Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 01-24-2014, 06:45 AM
troy23 troy23 is offline Mailmerge to a table from a txt file Windows 7 32bit Mailmerge to a table from a txt file Office 2007
Novice
Mailmerge to a table from a txt file
 
Join Date: Jan 2014
Posts: 4
troy23 is on a distinguished road
Default Mailmerge to a table from a txt file


Hi

I am trying to do a mailmerge from a txt file.

I need a table style mail merge.

I have some static fields at the top of the letter and in the body I need to show a table of data. I also need headings at the top of the table for each field. When I tried to do this the headings kept repeating for each record.

Any help and code appreciated.

Many thanks
Reply With Quote
  #2  
Old 01-24-2014, 09:20 PM
macropod's Avatar
macropod macropod is offline Mailmerge to a table from a txt file Windows 7 32bit Mailmerge to a table from a txt file Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,962
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

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/sho...merge-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.

For some worked examples, see the attachments to the posts at:
https://www.msofficeforums.com/mail-...html#post23345
https://www.msofficeforums.com/mail-...html#post30327
http://windowssecrets.com/forums/sho...l=1#post928391
Although these examples use Excel data sources, the principles are the same.

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://skydrive.live.com/?cid=5aedc...615E886B%21566
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #3  
Old 01-27-2014, 02:48 PM
troy23 troy23 is offline Mailmerge to a table from a txt file Windows 7 32bit Mailmerge to a table from a txt file Office 2007
Novice
Mailmerge to a table from a txt file
 
Join Date: Jan 2014
Posts: 4
troy23 is on a distinguished road
Default

Thanks

I tried this but how do you actually get the column headings in there and how to stop them repeating for every row?
Reply With Quote
  #4  
Old 01-27-2014, 03:10 PM
macropod's Avatar
macropod macropod is offline Mailmerge to a table from a txt file Windows 7 32bit Mailmerge to a table from a txt file Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,962
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

By adding the column headings to the field codes where indicated and using a Catalogue/Directory merge rather than a Letter merge.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #5  
Old 01-28-2014, 06:34 AM
troy23 troy23 is offline Mailmerge to a table from a txt file Windows 7 32bit Mailmerge to a table from a txt file Office 2007
Novice
Mailmerge to a table from a txt file
 
Join Date: Jan 2014
Posts: 4
troy23 is on a distinguished road
Default

Can you be more specific please?

It only says

The following example prefaces each City in the list with some introductory text, adds some headings and changes the format of the sales field.
[«City» «Representative» «Sales»
]
The fields laid out in this example produce the following output, using the ‘State’ field as the key field:
These are the sales totals for ACT
City Representative Sales
Canberra Yang $2,100.00


Nothing in there to state what is actually outputting the heading in bold.
Reply With Quote
  #6  
Old 01-28-2014, 02:32 PM
macropod's Avatar
macropod macropod is offline Mailmerge to a table from a txt file Windows 7 32bit Mailmerge to a table from a txt file Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,962
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

It would appear you haven't read the tutorial's Introduction ... On page 1 is a discussion titled 'Viewing The Fields'.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #7  
Old 01-29-2014, 03:11 AM
troy23 troy23 is offline Mailmerge to a table from a txt file Windows 7 32bit Mailmerge to a table from a txt file Office 2007
Novice
Mailmerge to a table from a txt file
 
Join Date: Jan 2014
Posts: 4
troy23 is on a distinguished road
Default

Paul I've done that but all I see is

{MERGEFIELD State} {MERGEFIELD City}

Can you please state how I get the word 'State' and 'City' to appear as headings to this merge data?

Thanks
Reply With Quote
  #8  
Old 01-29-2014, 04:40 AM
macropod's Avatar
macropod macropod is offline Mailmerge to a table from a txt file Windows 7 32bit Mailmerge to a table from a txt file Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,962
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

That would be because you didn't select the whole field - bounded by the [ ] characters for ease of boundary definition - before pressing SHift-F9. Try pressing Alt-F9.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
Reply

Tags
mailmerge, txt



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mailmerge to a table from a txt file Mailmerge to Email with a mailmerge attachment Baldeagle Mail Merge 8 02-11-2013 04:40 AM
Mailmerge to a table from a txt file Mailmerge to Email with a mailmerge attachment Baldeagle Mail Merge 13 05-29-2012 02:04 PM
Is it possible to link an Excel File to a Word table? KIM SOLIS Excel 9 09-08-2011 07:05 AM
A Table of Contents that Will Dictate the Content of the File ddhardy Word 0 06-23-2010 06:01 AM
Mailmerge to a table from a txt file extracting data from Table to text file Anirudh_Dsp Word Tables 1 05-23-2010 07:48 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 08:41 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft