Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
extracting address from a word document and merging them to label
I have a word document with several sections. At the begining of each
section, there is a vendor name and address. I want to creat a label merge that copies the addresses contained at the beg. of each section onto the labels. Is this possible? |
#2
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
extracting address from a word document and merging them to label
It is possible to do such a thing using Visual Basic. For a document with
only several sections, it is probably not worth the effort of creating the necessary macro, unless it is something that you have to do on a regular basis. To give any specific information on how to go about it, it would be necessary for you to provide additional information on how the address appears at the beginning of each section of the document. -- 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 "Freida" wrote in message ... I have a word document with several sections. At the begining of each section, there is a vendor name and address. I want to creat a label merge that copies the addresses contained at the beg. of each section onto the labels. Is this possible? |
#3
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
extracting address from a word document and merging them to la
The 1st 4 lines of each section include the vendor name and the address.
This is something that will need to be done on a regular basis, I made need the macro for this one. At any give time this doc. Can have anywhere from 10 to 40 sections depending on how often the report is ran. "Doug Robbins - Word MVP" wrote: It is possible to do such a thing using Visual Basic. For a document with only several sections, it is probably not worth the effort of creating the necessary macro, unless it is something that you have to do on a regular basis. To give any specific information on how to go about it, it would be necessary for you to provide additional information on how the address appears at the beginning of each section of the document. -- 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 "Freida" wrote in message ... I have a word document with several sections. At the begining of each section, there is a vendor name and address. I want to creat a label merge that copies the addresses contained at the beg. of each section onto the labels. Is this possible? |
#4
Posted to microsoft.public.word.mailmerge.fields
|
|||
|
|||
extracting address from a word document and merging them to la
And is each line a separate paragraph ending in a ¶ (when you click on the
Show/Hide button (¶))? If that is the case, this code should do it: Dim i As Long, j As Long Dim source As Document, target As Document Dim arange As Range, srange As Range Set source = ActiveDocument Set target = Documents.Add With source For i = 1 To .Sections.Count For j = 1 To 3 Set srange = .Sections(i).Range Set arange = srange.Paragraphs(j).Range arange.End = arange.End - 1 target.Range.InsertAfter arange & vbTab Next j Set arange = srange.Paragraphs(4).Range target.Range.InsertAfter arange Next i End With -- 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 "Freida" wrote in message ... The 1st 4 lines of each section include the vendor name and the address. This is something that will need to be done on a regular basis, I made need the macro for this one. At any give time this doc. Can have anywhere from 10 to 40 sections depending on how often the report is ran. "Doug Robbins - Word MVP" wrote: It is possible to do such a thing using Visual Basic. For a document with only several sections, it is probably not worth the effort of creating the necessary macro, unless it is something that you have to do on a regular basis. To give any specific information on how to go about it, it would be necessary for you to provide additional information on how the address appears at the beginning of each section of the document. -- 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 "Freida" wrote in message ... I have a word document with several sections. At the begining of each section, there is a vendor name and address. I want to creat a label merge that copies the addresses contained at the beg. of each section onto the labels. Is this possible? |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
word adding additional text merging e-mail address from access | Mailmerge | |||
MS Word merging data into a single document from Database | Mailmerge | |||
WP merge file to Word | Tables | |||
Why isn't all my Excel data merging into my Word labels document? | Mailmerge | |||
How do I create & merge specific data base & master documents? | New Users |