-
Open word document
Hi to all!
I have a silple need:
I need a macro to open a word document, execute mailmerge and update a excel link inside this document.
If possible, I don't want it ask me if I want to update link and mailmerge, just open it and automaticaly do those changes.
Thanks in advance
-
-
It is easier to help if you include simple example files.
That is not all that simple. It should be easier if you review my mail merge example files, last link in mail merge. The updating link part would be needed.
Option Explicit
'TypeText method
' http://www.excelforum.com/excel-prog...ml#post1946784
' http://www.excelforum.com/showthread.php?p=1946784
' http://vbaexpress.com/forum/showthread.php?p=169877
' http://vbaexpress.com/forum/showthread.php?t=24693
' http://www.excelforum.com/excel-prog...age-setup.html
'Copy from Excel, paste to Word
'Lucas, http://vbaexpress.com/forum/showthread.php?p=178364
'FormFields
' http://www.mrexcel.com/forum/showthread.php?p=1639696
' http://www.mrexcel.com/forum/showthread.php?t=333200
' http://www.excelforum.com/excel-prog...from-word.html
' Content Controls
' http://www.vbaexpress.com/forum/showthread.php?t=39654
'Add Hyperlink to Bookmark
' http://www.excelforum.com/excel-prog...ml#post2006430
'Steiner, http://www.vbaexpress.com/kb/getarticle.php?kb_id=126
'Colin_L, http://www.mrexcel.com/forum/showthread.php?t=358054
'Save OLEObject as MSWord Document
' http://vbaexpress.com/forum/showthread.php?t=21619
' http://vbaexpress.com/forum/showthread.php?t=24292
' http://www.excelforum.com/excel-prog...html?p=3336342
'Add Table to MSWord
' http://vbaexpress.com/forum/showthread.php?t=23975
' http://vbaexpress.com/forum/showthread.php?p=168731
'Import Word Tables
'vog, http://www.mrexcel.com/forum/showthread.php?t=382541
'Ruddles, http://www.mrexcel.com/forum/showthread.php?t=524091
'snb, Word Tables
' http://www.vbaexpress.com/forum/showthread.php?t=45520
' http://www.vbaexpress.com/forum/showthread.php?t=46472
'Get Optionbutton info from MSWord DOC
' http://vbaexpress.com/forum/showthread.php?t=22454
'FindReplace Text
' http://www.excelforum.com/excel-prog...-ms-excel.html
' http://www.vbaexpress.com/forum/showthread.php?t=38958
' http://www.vbaexpress.com/forum/showthread.php?p=250215
' http://www.vbaexpress.com/forum/showthread.php?t=42833
' http://support.microsoft.com/kb/240157
' http://word.tips.net/T001833_Generat...currences.html
' http://www.excelforum.com/excel-prog...o-to-word.html
'Bookmarks
' http://vbaexpress.com/forum/showthread.php?p=185718
'Colin_L, http://www.mrexcel.com/forum/showthread.php?t=358054
' http://www.vbaexpress.com/forum/showthread.php?p=253277
'Mail Merge
' http://www.excelforum.com/excel-prog...rom-excel.html
' http://www.excelforum.com/excel-prog...-document.html
'Word 's Catalogue/Directory Mailmerge facility (the terminology depends on the Word version). _
To see how to group records with any mailmerge data source supported by Word, _
check out my Microsoft Word Catalogue/Directory Mailmerge Tutorial at:
' http://lounge.windowssecrets.com/ind...owtopic=731107
' or
' http://www.gmayor.com/Zips/Catalogue%20Mailmerge.zip
' Mail Merge from Excel to MSWord: ElephantsRus
' https://app.box.com/s/0zlydxinl10t23mifkrr
-
Thanks for the replies.
I don't want to sound lazy, but those links seem a lot of work for something I think is simple (I'm really inexperienced on VBA and excel in general).
I guess I didn't express myself very well.
My word document is done, with mergefields set and working, as the spreadsheet link.
WHat I need is a macro to open this word document and execute the merge and excel link that are already set up.
-
Still with this problem...
-
I gave you the solution. I don't know how much more simple that can be. Simply look at snb's reply in the first mail merge link that I gave you.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules