Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Append two documents to one, how
I've got a series of exams and solution sets. When I first made them
up, it seemed easy to have the exam and solutions as separate documents; but for archiving I think I'd rather have the solutions and exam in the same document (with an "odd page" section break between them). How do I append the solutions document to the exam document without screwing up the formatting of either one? I know that I'll have to fix the "page N of NN" in the headers to reference the number of pages within section, but is there anything else to watch out for? (Seems to me there was a reference in the group to a document about this. I've just spent some time at http://word.mvps.org/Search/index.htm but searches for "join documents" and "append documents" didn't turn up anything.) -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "My theory was a perfectly good one. The facts were misleading." -- /The Lady Vanishes/ (1938) |
#2
|
|||
|
|||
Here's a macro that I created for another poster who wanted to create a
document by combining alternate pages from two other documents. It might do what you want: Dim sourcea As Document, sourceb As Document, target As Document, Pages As Integer, Counter As Integer, targetrange As Range 'targetrange added Dim evenpage As Range Set sourcea = Documents.Open(FileName:="...") sourcea.Repaginate Pages = ActiveDocument.BuiltInDocumentProperties(wdPropert yPages) MsgBox Pages Set sourceb = Documents.Open(FileName:="...") Set target = Documents.Add target.PageSetup.LeftMargin = sourcea.PageSetup.LeftMargin target.PageSetup.RightMargin = sourcea.PageSetup.RightMargin target.PageSetup.TopMargin = sourcea.PageSetup.TopMargin target.PageSetup.BottomMargin = sourcea.PageSetup.BottomMargin target.AcceptAllRevisions Counter = 0 While Counter Pages sourcea.Activate ActiveDocument.Bookmarks("\page").Range.Copy Set targetrange = target.Range targetrange.Start = targetrange.End targetrange.Paste ActiveDocument.Bookmarks("\page").Range.Cut sourceb.Activate 'Assumed to be the document containing the even pages Selection.EndKey Unit:=wdStory 'Line of code added to start from the end of the document ActiveDocument.Bookmarks("\page").Range.Copy Set targetrange = target.Range targetrange.Start = targetrange.End targetrange.Paste targetrange.Start = targetrange.End targetrange.InsertBreak Type:=wdPageBreak Set evenpage = ActiveDocument.Bookmarks("\page").Range evenpage.Start = evenpage.Start - 1 evenpage.Delete Counter = Counter + 1 Wend sourcea.Close wdDoNotSaveChanges sourceb.Close wdDoNotSaveChanges -- 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 "Stan Brown" wrote in message ... I've got a series of exams and solution sets. When I first made them up, it seemed easy to have the exam and solutions as separate documents; but for archiving I think I'd rather have the solutions and exam in the same document (with an "odd page" section break between them). How do I append the solutions document to the exam document without screwing up the formatting of either one? I know that I'll have to fix the "page N of NN" in the headers to reference the number of pages within section, but is there anything else to watch out for? (Seems to me there was a reference in the group to a document about this. I've just spent some time at http://word.mvps.org/Search/index.htm but searches for "join documents" and "append documents" didn't turn up anything.) -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "My theory was a perfectly good one. The facts were misleading." -- /The Lady Vanishes/ (1938) |
#3
|
|||
|
|||
See http://word.mvps.org/FAQs/Formatting...thSections.htm for one aspect
of the problem. -- Suzanne S. Barnhill Microsoft MVP (Word) Words into Type Fairhope, Alabama USA Word MVP FAQ site: http://word.mvps.org Email cannot be acknowledged; please post all follow-ups to the newsgroup so all may benefit. "Stan Brown" wrote in message ... I've got a series of exams and solution sets. When I first made them up, it seemed easy to have the exam and solutions as separate documents; but for archiving I think I'd rather have the solutions and exam in the same document (with an "odd page" section break between them). How do I append the solutions document to the exam document without screwing up the formatting of either one? I know that I'll have to fix the "page N of NN" in the headers to reference the number of pages within section, but is there anything else to watch out for? (Seems to me there was a reference in the group to a document about this. I've just spent some time at http://word.mvps.org/Search/index.htm but searches for "join documents" and "append documents" didn't turn up anything.) -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "My theory was a perfectly good one. The facts were misleading." -- /The Lady Vanishes/ (1938) |
#4
|
|||
|
|||
On Wed, 24 Aug 2005 17:32:31 -0500, "Suzanne S. Barnhill"
wrote: "Stan Brown" wrote in message .. . I've got a series of exams and solution sets. When I first made them up, it seemed easy to have the exam and solutions as separate documents; but for archiving I think I'd rather have the solutions and exam in the same document (with an "odd page" section break between them). How do I append the solutions document to the exam document without screwing up the formatting of either one? I know that I'll have to fix the "page N of NN" in the headers to reference the number of pages within section, but is there anything else to watch out for? See http://word.mvps.org/FAQs/Formatting...thSections.htm for one aspect of the problem. This was one of the documents I looked at, but frankly I didn't understand how it relates to my problem. Maybe I'm extra stupid today, -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." |
#5
|
|||
|
|||
On Wed, 24 Aug 2005 22:36:09 +0200, "Doug Robbins"
wrote: "Stan Brown" wrote in message .. . How do I append the solutions document to the exam document without screwing up the formatting of either one? I know that I'll have to fix the "page N of NN" in the headers to reference the number of pages within section, but is there anything else to watch out for? Here's a macro that I created for another poster who wanted to create a document by combining alternate pages from two other documents. It might do what you want: Thanks for posting, Doug. This would actually be pretty slick if the solutions were paginated the same as the exam questions, but unfortunately they're not. What I'm trying to do is something less ambitions: take document B and put it at the end of document A, then save it as C so that if I right-click on document C and select "Print" I'll get what I formerly got from separately printing A and B separately. -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." |
#6
|
|||
|
|||
How do I append the solutions document to the exam document without screwing up the formatting of either one? I know that I'll have to fix the "page N of NN" in the headers to reference the number of pages within section, but is there anything else to watch out for? See http://word.mvps.org/FAQs/Formatting...thSections.htm for one aspect of the problem. This was one of the documents I looked at, but frankly I didn't understand how it relates to my problem. Maybe I'm extra stupid today, Sections 2 and 4 should be directly relevant, depending on the method you choose. But this also depends on what formatting you are trying to keep. The page is basically about keeping different headers and footers and other section formatting properties. If you want the Body Text style to have one appearance in the Exam section and a different appearance in the Solutions section, no can do. Daiya |
#7
|
|||
|
|||
On Fri, 26 Aug 2005 10:01:18 -0700, Daiya Mitchell
wrote: Sections 2 and 4 should be directly relevant, depending on the method you choose. But this also depends on what formatting you are trying to keep. The page is basically about keeping different headers and footers and other section formatting properties. If you want the Body Text style to have one appearance in the Exam section and a different appearance in the Solutions section, no can do. That sounds like there's no easy way to append two documents together without losing the styles of one of them. (Obviously I could rename all the styles of one, but that's not exactly easy. :-) -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." "I was misinformed." |
#8
|
|||
|
|||
All you have to do is use Ctrl+a in one document to select everything, then
Ctrl+c to copy it to the clipboard, then go to the end of the other document and use Ctrl+v to paste the information from the clipboard into that document. Save with a different name if you need to. -- 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 "Stan Brown" wrote in message ... On Wed, 24 Aug 2005 22:36:09 +0200, "Doug Robbins" wrote: "Stan Brown" wrote in message . .. How do I append the solutions document to the exam document without screwing up the formatting of either one? I know that I'll have to fix the "page N of NN" in the headers to reference the number of pages within section, but is there anything else to watch out for? Here's a macro that I created for another poster who wanted to create a document by combining alternate pages from two other documents. It might do what you want: Thanks for posting, Doug. This would actually be pretty slick if the solutions were paginated the same as the exam questions, but unfortunately they're not. What I'm trying to do is something less ambitions: take document B and put it at the end of document A, then save it as C so that if I right-click on document C and select "Print" I'll get what I formerly got from separately printing A and B separately. -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." |
#9
|
|||
|
|||
There is one way - turn them into .pdfs and combine them into one document.
I do that often. -- JoAnn Paules MVP Microsoft [Publisher] "Stan Brown" wrote in message ... On Fri, 26 Aug 2005 10:01:18 -0700, Daiya Mitchell wrote: Sections 2 and 4 should be directly relevant, depending on the method you choose. But this also depends on what formatting you are trying to keep. The page is basically about keeping different headers and footers and other section formatting properties. If you want the Body Text style to have one appearance in the Exam section and a different appearance in the Solutions section, no can do. That sounds like there's no easy way to append two documents together without losing the styles of one of them. (Obviously I could rename all the styles of one, but that's not exactly easy. :-) -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." "I was misinformed." |
#10
|
|||
|
|||
If you want the Body Text style to have one
appearance in the Exam section and a different appearance in the Solutions section, no can do. That sounds like there's no easy way to append two documents together without losing the styles of one of them. (Obviously I could rename all the styles of one, but that's not exactly easy. :-) Well, the point of using styles is consistency throughout a document, so no, there's no "per section" setting for styles. Try JoAnn's PDF method. -- Daiya Mitchell, MVP Mac/Word Word FAQ: http://www.word.mvps.org/ MacWord Tips: http://www.word.mvps.org/MacWordNew/ What's an MVP? A volunteer! Read the FAQ: http://mvp.support.microsoft.com/ |
#11
|
|||
|
|||
My head is gonna explode. First Graham agreed with me, now you. Dang! I must
be better than I thought. :-) -- JoAnn Paules MVP Microsoft [Publisher] "Daiya Mitchell" wrote in message .. . If you want the Body Text style to have one appearance in the Exam section and a different appearance in the Solutions section, no can do. That sounds like there's no easy way to append two documents together without losing the styles of one of them. (Obviously I could rename all the styles of one, but that's not exactly easy. :-) Well, the point of using styles is consistency throughout a document, so no, there's no "per section" setting for styles. Try JoAnn's PDF method. -- Daiya Mitchell, MVP Mac/Word Word FAQ: http://www.word.mvps.org/ MacWord Tips: http://www.word.mvps.org/MacWordNew/ What's an MVP? A volunteer! Read the FAQ: http://mvp.support.microsoft.com/ |
#12
|
|||
|
|||
On Sat, 27 Aug 2005 07:48:51 +0200, "Doug Robbins"
wrote: All you have to do is use Ctrl+a in one document to select everything, then Ctrl+c to copy it to the clipboard, then go to the end of the other document and use Ctrl+v to paste the information from the clipboard into that document. That's if the two documents have identical styles and page setup elements such as headers and footers. -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." "I was misinformed." |
#13
|
|||
|
|||
On Sat, 27 Aug 2005 08:14:00 -0400, "JoAnn Paules [MSFT MVP]"
wrote: There is one way - turn them into .pdfs I thought I remembered reading here that Office doesn't export to PDF natively? -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." "I was misinformed." |
#14
|
|||
|
|||
On 8/27/05 8:36 PM, "Stan Brown" wrote:
On Sat, 27 Aug 2005 08:14:00 -0400, "JoAnn Paules [MSFT MVP]" wrote: There is one way - turn them into .pdfs I thought I remembered reading here that Office doesn't export to PDF natively? It doesn't. Ton of freeware/shareware/cheaper alternatives to Acrobat out there. I think JoAnn uses PrimoPDF, also seen CutePDF and PDF1995 mentioned. Check 'em out. Though, on second thought it occurred to me that--can't you find the efficiency you are looking for by selecting two documents in Windows Explorer and right-clicking to Print, or somesuch? And do you really want to risk the situation where you email students a sample exam and forget you had been trying to be all efficient and give them the answers as well? I'm not really sure having 1 doc is all that more efficient for archiving than having 2. Putting two printouts in the same file folder is more efficient, yes, but on the computer? Daiya |
#15
|
|||
|
|||
On 8/27/05 8:35 PM, "Stan Brown" wrote:
On Sat, 27 Aug 2005 07:48:51 +0200, "Doug Robbins" wrote: All you have to do is use Ctrl+a in one document to select everything, then Ctrl+c to copy it to the clipboard, then go to the end of the other document and use Ctrl+v to paste the information from the clipboard into that document. That's if the two documents have identical styles and page setup elements such as headers and footers. As it turns out...see Klaus Linke's second post on this thread: http://groups.google.com/group/micro...ment/browse_fr m/thread/2a507242995575b5/2fba9c46b1bfb4d8?lnk=raot#2fba9c46b1bfb4d8 [long URL may break] -- Daiya Mitchell, MVP Mac/Word Word FAQ: http://www.word.mvps.org/ MacWord Tips: http://www.word.mvps.org/MacWordNew/ What's an MVP? A volunteer! Read the FAQ: http://mvp.support.microsoft.com/ |
#16
|
|||
|
|||
Actually I use Acrobat Pro v7 but I also have PrimoPDF that I've tested so
that I could pass the information along to fellow guild editors. -- JoAnn Paules MVP Microsoft [Publisher] "Daiya Mitchell" wrote in message .. . On 8/27/05 8:36 PM, "Stan Brown" wrote: On Sat, 27 Aug 2005 08:14:00 -0400, "JoAnn Paules [MSFT MVP]" wrote: There is one way - turn them into .pdfs I thought I remembered reading here that Office doesn't export to PDF natively? It doesn't. Ton of freeware/shareware/cheaper alternatives to Acrobat out there. I think JoAnn uses PrimoPDF, also seen CutePDF and PDF1995 mentioned. Check 'em out. Though, on second thought it occurred to me that--can't you find the efficiency you are looking for by selecting two documents in Windows Explorer and right-clicking to Print, or somesuch? And do you really want to risk the situation where you email students a sample exam and forget you had been trying to be all efficient and give them the answers as well? I'm not really sure having 1 doc is all that more efficient for archiving than having 2. Putting two printouts in the same file folder is more efficient, yes, but on the computer? Daiya |
#17
|
|||
|
|||
On Sun, 28 Aug 2005 01:46:55 -0700, Daiya Mitchell
wrote: Though, on second thought it occurred to me that--can't you find the efficiency you are looking for by selecting two documents in Windows Explorer and right-clicking to Print, or somesuch? The goal was to archive them on CD and make sure the exam and its solutions never get separated. Needless to say, since I recognized this problem I've been creating them as a single documents from the get-go. And do you really want to risk the situation where you email students a sample exam and forget you had been trying to be all efficient and give them the answers as well? :-) That would be a concern, I agree. But I have sample exams on the class Web pages, so I think I'm covered there. -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." "I was misinformed." |
#18
|
|||
|
|||
On Sun, 28 Aug 2005 01:46:55 -0700, Daiya Mitchell
wrote: On 8/27/05 8:36 PM, "Stan Brown" wrote: I thought I remembered reading here that Office doesn't export to PDF natively? It doesn't. Ton of freeware/shareware/cheaper alternatives to Acrobat out there. I think JoAnn uses PrimoPDF, also seen CutePDF and PDF1995 mentioned. Check 'em out. Thanks. (I saw JoAnn's follow-up to the effect that she actually uses an Acrobat product but keeps PrimoPDF around to see how the other half lives.grin) I think PDF would be overkill for this particular project -- and based on the comments I'm coming to the conclusion that doing much of anything is overkill for this particular project -- but it's worth adding to my toolbag for the long term. -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." "I was misinformed." |
#19
|
|||
|
|||
Hey now! I *am* the other half. ;-)
The copy of Acrobat I have was purchased by the organization I belong to. I do the newsletter and website and it's very nice for getting our information out to our members. If they hadn't agreed to the purchase, I'd be using PrimoPDF. -- JoAnn Paules MVP Microsoft [Publisher] "Stan Brown" wrote in message ... On Sun, 28 Aug 2005 01:46:55 -0700, Daiya Mitchell wrote: On 8/27/05 8:36 PM, "Stan Brown" wrote: I thought I remembered reading here that Office doesn't export to PDF natively? It doesn't. Ton of freeware/shareware/cheaper alternatives to Acrobat out there. I think JoAnn uses PrimoPDF, also seen CutePDF and PDF1995 mentioned. Check 'em out. Thanks. (I saw JoAnn's follow-up to the effect that she actually uses an Acrobat product but keeps PrimoPDF around to see how the other half lives.grin) I think PDF would be overkill for this particular project -- and based on the comments I'm coming to the conclusion that doing much of anything is overkill for this particular project -- but it's worth adding to my toolbag for the long term. -- Stan Brown, Oak Road Systems, Tompkins County, New York, USA http://OakRoadSystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." "I was misinformed." |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Master/Outline documents of substantial length | Formatting Long Documents | |||
print multiple documents or merge multiple documents into one | Microsoft Word Help | |||
Problems merging multiple Word documents | Microsoft Word Help | |||
Wordperfect Office 2000 conversion to Word 2003 | New Users | |||
Boiletplates from Word Perfect | Microsoft Word Help |