January 23, 2018, 04:05:59 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
   Home   News Alerts Help Search Calendar Members Contributions Staff List Login Register  
NOD32 v3.0 - Save 25% - Download Now 2 Night Free Hotel Stay Banner Big Selection of Computer Memory from MemoryGiant. battery superstore Digg FURL FaceBook Stumble Upon Reddit SlashDot Google Bookmarks

Pages: 1   Go Down
  Add bookmark  |  Print  
Author Topic: Merging Multiple Word Docs  (Read 2688 times)
0 Members and 1 Guest are viewing this topic.
Global Moderator
Offline Offline

Gender: Female
Occupation: Supervisor - Field Audit Services
Location: California
Experience: 1989
Posts: 35


Home of the Free because of the Brave

View Profile
« on: June 01, 2010, 12:51:26 PM »

I have, on occasion, had to add multiple word documents into a single document.  Cutting and pasteing can be cumbersome for more than just a few letters, soooo Try this.... create a folder and drop in copies of the docs you want merged together.  Then copy and paste the below into a macro in a new document.  (Be sure to change the "file location" to where you have created your folder) also.. it is VERY important to have the last "\" or it will return a blank doc.

Also, if you need your letters in a particular order, you should change the names to add 1, 2, 3, etc so that they will be merged in the correct order. I merged 55 docs for an operations manual and it came out awesome!

If you need the pages to NOT run together, you will need page breaks either on each page or added after the merge.   Have fun!

Sub MergeDocs()
Dim rng As Range
Dim FinalEvidence As Document
Dim strFile As String
'Dim OutPut_file_name As String
Const strFolder = "C:\Test\" *delete this, but change to dir string for items to be merged, remember the final \
Set FinalEvidence = Documents.Add
strFile = Dir$(strFolder & "*.doc")
Do Until strFile = ""
Set rng = FinalEvidence.Range
rng.Collapse wdCollapseEnd
rng.InsertFile strFolder & strFile
strFile = Dir$()
Selection.InsertBreak Type:=wdPageBreak
' OutPut_file_name = "new document name.doc"
End Sub

Global Moderator
Offline Offline

Gender: Male
Experience: 1984
Posts: 73


"Ehh, what's up, doc?"

View Profile WWW
« Reply #1 on: June 08, 2010, 10:01:06 AM »

Very interesting AuditorLisa!  I'll give that a try sometime Smiley

Click Here - Free Trial of ESET NOD32 Antivirus
Pages: 1   Go Up
  Add bookmark  |  Print  
Jump to:  

Related Topics
Subject Started by Replies Views Last post
A word about Browsers and Links Announcements auditor1 0 2975 Last post August 01, 2008, 05:52:34 PM
by auditor1
Excel & Word 2003 to 2007 command reference guide Excel beancounter 0 2470 Last post May 25, 2009, 11:57:42 AM
by beancounter
Free Word, Excel and PowerPoint Tech Talk AuditorBob 1 4508 Last post August 02, 2010, 11:20:26 AM
by auditor1
Word 2010 - AutoText Tech Talk AuditorLisa 1 7570 Last post September 24, 2012, 12:59:02 PM
by beancounter

"> 4inkjets! Ink and Toner Cartridges WebEx MeetMeNow Online Meetings - Faxing Simplified Acrobat 8 pro 250x250 Replacement AC Adapters - 1 year warranty
Purchase Trend Micro Internet Security 2008 and ge Compusa (Systemax, Inc.)
Free 3D Koi Fish Screensaver
Free Solar System Screensavers! Compusa (Systemax, Inc.)
SYNCING.NET - Try it now for free SYNCING.NET - Do your Pcs talk to each other

Unique Hits: 1851163
Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines
AuditBible © 2008 | Sitemap
Valid XHTML 1.0! Valid CSS!