5 Replies Latest reply on Jul 15, 2014 4:34 PM by TᴀW

    How Do I combine 2 InDesign Documents into 1 (in a very particular way)

    CafeRon

      How do I combine two InDesign Documents into one in a very specific way.

       

      Here's my problem: I have two separate InDesign CS5 files for playing cards. File one is the front. File two is the back.

       

      The company that does my final print production needs the the cards sent as two separate PDFs. One for the card fronts, one for the card backs. Both of these InDesign (and the PDF export) files are arranged in the same way: page 1 is card #1, page 2 is card #2, etc. Nice and simple.

       

      However, I use a different company for producing prototype versions of the decks (the production printer can't do this economically). My prototype producer needs me to send a single PDF where page 1 is Card #1 Back, page 2 is Card #1 Front, Page 3 is Card #2 back, Page 4 is Card #2 front, etc.

       

      The decks I am building usually run 56 cards, but can be as large as 180 cards.

       

      So, what's the easiest way to automate this process? is there a way to combine two separate indesign files by "interleaving" the pages from the two original documents into a new larger document (where I could do a new PDF export)?  Or, is there a better way to do this in Acrobat Pro? At the moment I have to resort to drag and dropping each card from one PDF thumbnail pallet to the other. It's really time consuming and mind-numbingly boring.  Any Ideas?

        • 1. Re: How Do I combine 2 InDesign Documents into 1 (in a very particular way)
          TᴀW Adobe Community Professional & MVP

          Unless someone here can come up with something ingenious, I think the

          simple answer is that you need a script.

          • 2. Re: How Do I combine 2 InDesign Documents into 1 (in a very particular way)
            CafeRon Level 1

            I figured that might be the case.  However, which script would be easier to create and would be flexible enough to handle different-sized documents?  I need this process to be repeatable, and simple so that I can add it to my workflow for many projects to caom.

            • 3. Re: How Do I combine 2 InDesign Documents into 1 (in a very particular way)
              TᴀW Adobe Community Professional & MVP

              Surely you don't mean that the document with the back of the cards is a

              different page size to the document with the front of the cards?

               

              If both documents (back and front) do indeed use the same page size, it

              would make no difference to the script what the specific size is.

              • 4. Re: How Do I combine 2 InDesign Documents into 1 (in a very particular way)
                CafeRon Level 1

                Yes, the page sizes are the same.  I just want to be able to write a script that can is easily transferable from one project to the next. Project #1 might have 24 cards, project #2 might have 168 cards, and Project #3 might have 180 cards.  Any given project could have all the same back, or any number of different backs.

                 

                So, given that my familiarity with scripting is practically nil (outside of creating macros in Photoshop, and saving complicates Find-&-Replace scripts in PageMaker (boy that takes me back...). Which program's scripting would be better suited to the task, InDesign's or Acrobat's?

                 

                Then the follow-up, what's the best place to start to learn/delve into said scripting. Something written for people who are only moderately familiar with the process?

                • 5. Re: How Do I combine 2 InDesign Documents into 1 (in a very particular way)
                  TᴀW Adobe Community Professional & MVP

                  This script is actually pretty straightforward, so it's a good first

                  challenge I think.

                   

                  I would script this in InDesign -- probably because I'm more familiar

                  with InDesign scripting.

                   

                  To start learning the InDesign scripting basics, open the ExtendScript

                  Toolkit (ESTK) which is almost certainly installed on your computer

                  already. Go to the Help menu, and you'll find an entry there called

                  Adobe Intro to Scripting. Read that. I think that's the best place to start.

                   

                  For the script in question, you would want to:

                  1. make sure both InDesign documents are open. They would both have the

                  same number of pages. (No scripting involved here, just make sure

                  they're open before running the script.)

                  2. loop backwards through the collection of document pages of one of the

                  documents. (document.pages is the collection you're looking for)

                  3. use the move() method of a document page to move it. (myPage.move())

                  4. Learn about the LocationOptions enumerator so that when you move the

                  page you can tell InDesign if you want to move it before, or after

                  another page. (LocationOptions.AFTER or LocationOptions.BEFORE)

                  5. Get a reference to the page in the second document before (or after)

                  which you want to move the page in the first document.

                  5. that's basically it

                   

                  I suggest that as you work your way through this (if you decide to take

                  up the challenge), you post any questions you may have on the InDesign

                  Scripting forum here.