Home |
Search |
Today's Posts |
#13
![]()
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
![]()
Thank you macropod. Your solution worked perfectly.
Many thanks to all that have helped me out on this. all the best. "macropod" wrote: Hi APP, Using the first example under the heading "Inserting Text After the Repeated Data", you can repeat the 'Key' field's value after the repeated text by making, the following mods to the field code: 1. Change the first line by adding '{SET LastKey { Key }' thus: {QUOTE{IF{ MERGESEQ }= 1 {SET Key ""} {SET LastKey { Key }}}"{IF{ MERGEFIELD State } { Key } "{IF{ MERGESEQ } 1 " 2. Replace the word 'State' in "please contact your State Sales Manager" with a field coded as {REF LastKey}. That's all you need to do. Adapt as needed for your own requirements. -- Cheers macropod [Microsoft MVP - Word] "APP" wrote in message ... Hi everyone and thank you all for your input. Unfortunately they have not resulted in working solution for me. I have the tutorial correctly, yet the tutorial does not provide a case where the key field is in the text to apear after repeating data... I have tried your solution Doug but I get all sorts of error messages.... Perhaps you see for your self using the tutorial and addind the key field (state) in the text to appear after the repeating data. You will get the next value in the data base for the state!!!! Perhaps there's a merge code to say take value-1?! thanks "Doug Robbins - Word MVP" wrote: Hi Paul, Yes, the code was written for use with an Excel 97-2003 data source. While most other data sources could be copied/pasted/exported to that format, it would not be too difficult to come up with code for use with a Word datasource. For data in Access. it can certainly be exported to Excel. -- Hope this helps, Doug Robbins - Word MVP Please reply only to the newsgroups unless you wish to obtain my services on a paid professional basis. "macropod" wrote in message ... Hi Doug, If I understand the article correctly, your new method only works with Excel data sources. Is that correct? -- Cheers macropod [Microsoft MVP - Word] "Doug Robbins - Word MVP" wrote in message ... I have developed a new method that may be simpler for you to use. See the following page of fellow MVP Graham Mayors website: http://www.gmayor.com/ManyToOne.htm -- Hope this helps, Doug Robbins - Word MVP Please reply only to the newsgroups unless you wish to obtain my services on a paid professional basis. "APP" wrote in message ... Hi Doug, I have used the very useful tutorial you referenced. I added text after te repeated data. I have added a the key field as part of the text. The problem is that fr that specific field, the value returned is the next field in the data base. Where has it is te correct field in th repeated area. Here's an example: Dear X, Repeating data...with keyfield "productcompany" showing fine. Text after repeaed data.... On belhaf of "productcompany" . The problem is when in the repeated data part , the field value returns item i of the bdatabase, the same field is showing item 2 of the database in the text afer the repeated data. Thanks for your help. "Doug Robbins - Word MVP" wrote: See fellow MVP Macropod's "Word 97-2007 Catalogue/Directory Mailmerge Tutorial" at: http://www.wopr.com/index.php?showtopic=731107 or http://www.gmayor.com/Zips/Catalogue%20Mailmerge.zip Do read the tutorial before trying to use the mailmerge document included with it as you must get the mail merge main document set up exactly as required. -- Hope this helps. Please reply to the newsgroup unless you wish to avail yourself of my services on a paid consulting basis. Doug Robbins - Word MVP, originally posted via msnews.microsoft.com "budman42" wrote in message ... I have a list of accounts were 5 to 10 accounts are for the same person / member # (which is also a field) and I created a word doc that I want to merge with several enteries (the 5 to 10 entries of the same person) of the spread sheet.. Anyone have any ideas?? . . . |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Mail Merge in Word using Excel Spreadsheet | Microsoft Word Help | |||
Merge an excel spreadsheet into word | Mailmerge | |||
autocorrect enteries lost | Microsoft Word Help | |||
Will auto text work on multiple enteries of a word in Word 2003 | Microsoft Word Help | |||
Inserting a multiple page excel spreadsheet into Word | Microsoft Word Help |