Solved

Merging Portions of Word Documents

Posted on 2011-03-05
3
348 Views
Last Modified: 2012-06-21
Currently I recieve status reports in MS Word format from multiple techs which I then manually combine into one status report (by copying and pasting) which I send to my supervisor. I would like to automate the process of combining these status reports.  It's a pain.  

Attached is an example of the form I would use to combine all of the individual tech status report.  For the example I've put 2 items for each tech in each category but the number of items could be more or less than 2.  Of course in each of the tech's status report only their name would be on the form (not the other techs).

What would be be best way of combining these status reports and can someone help show me how?  I don't want to pay any licensing fees.  Am open to all suggestions.  Maybe a vb.net or vbs solution?    STATUS-REPORT-TEMPLATE-EE.DOC
0
Comment
Question by:BigBobBK
3 Comments
 
LVL 19

Expert Comment

by:MINDSUPERB
ID: 35046197
You may try to design your form in Excel or even better by Access. These two applications are appropriate if you collect data and combine them for reporting.

If you choose Excel, you can design a Sumary spreadsheet by which its data are linked from the spreasheet of each Technician. And with Access, you can distribute a Front End to each technician and whatever data they entered could be easily summarized.

I agree that these approaches could not be easily done but once completed and implemented, it will save you time and hassle.

Sincerely,
Ed
0
 
LVL 16

Expert Comment

by:sjklein42
ID: 35047042
This is some VB I use to build a document automatically.

You start with a DOC file containing your header boilerplate (headerDocument.doc).

The VB code then opens other files, copies and pastes them into the main document.

At the end, it saves it as a new document called finalReport.doc.

If you know VB you can get the idea pretty easily, I think.

Private Function PasteNow()
    Selection.WholeStory
    Selection.Copy
    Windows(1).Activate
    Selection.Paste
End Function

Private Function PasteInto(whichWindow)
    Windows(whichWindow).Activate
    Selection.WholeStory
    Selection.Copy
    Windows(1).Activate
    Selection.EndKey Unit:=wdStory
    Selection.Paste
End Function

Private Function InsertSectionBreak()
    Selection.EndKey Unit:=wdStory
    Selection.InsertBreak Type:=wdSectionBreakNextPage
End Function

Private Function PasteFile(whichFile)
    InsertSectionBreak
    
    Documents.Open FileName:=whichFile, ConfirmConversions:=False, _
        ReadOnly:=True, AddToRecentFiles:=False, PasswordDocument:="", _
        PasswordTemplate:="", Revert:=False, WritePasswordDocument:="", _
        WritePasswordTemplate:="", Format:=wdOpenFormatAuto
    PasteNow
End Function

Sub PasteFilesTogether()
    Documents.Open FileName:="c:\myworkdir\headerDocument.doc", ConfirmConversions:=False, ReadOnly _
        :=True, AddToRecentFiles:=False, PasswordDocument:="", PasswordTemplate _
        :="", Revert:=False, WritePasswordDocument:="", WritePasswordTemplate:="" _
        , Format:=wdOpenFormatAuto

    PasteFile("c:\myworkdir\inputFile_1.doc")
    PasteFile("c:\myworkdir\inputFile_2.doc")
    PasteFile("c:\myworkdir\inputFile_3.doc")
    PasteFile("c:\myworkdir\inputFile_4.doc")
    
    ActiveDocument.SaveAs FileName:="c:\myworkdir\finalReport.doc", FileFormat:= _
        wdFormatDocument, LockComments:=False, Password:="", AddToRecentFiles:= _
        False, WritePassword:="", ReadOnlyRecommended:=False, EmbedTrueTypeFonts:= _
        False, SaveNativePictureFormat:=False, SaveFormsData:=False, _
        SaveAsAOCELetter:=False

End Sub

Open in new window

0
 
LVL 45

Accepted Solution

by:
aikimark earned 500 total points
ID: 35061105
How about using a master document scheme where the master document includes references to the sub documents.  Although you see the content from the sub documents, the master document is much smaller.
0

Featured Post

Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In a previously published article (http://www.experts-exchange.com/articles/10331/Automatic-Duplex-Scanning-in-PaperPort-Versions-11-12-14.html) here at Experts Exchange, I explained how to achieve duplex (double-sided) scanning in Nuance's PaperPor…
This article shows how to convert a multi-page PDF file into multiple image files, with one image file created for each page of the PDF. It does this by utilizing an excellent, free software package called GraphicsMagick. The solution is amazingly s…
Office 365 is currently available in five editions. Three of them are for business use: Office 365 Business Essentials, Office 365 Business, and Office 365 Business Premium. Two of them are for home/personal use: Office 365 Home and Office 365 Perso…
This video Micro Tutorial is the first in a two-part series that shows how to create and use custom scanning profiles in Nuance's PaperPort 14.5 (http://www.experts-exchange.com/articles/17490/). But the ability to create custom scanning profiles al…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question