2 Replies Latest reply on Nov 20, 2015 12:50 PM by Peter Spier

    Long document problem


      I have a long book (253 pages in Word) that was sent to me to be placed into InDesign 5.5. The problem that I ran into is that when I flow it into the program it stays as a single section rather than breaking up by chapter as I have seen done previously. I would like to break it down into more manageable chunks and also want to change the footnote numbering but am not sure how. If anyone can understand my plight and could help me out it would be greatly appreciated, thank you.

        • 1. Re: Long document problem
          Migintosh Level 4

          Do a Save-As for each chapter you want, and delete what ever doesn't belong in that chapter and save. Then, use the Book feature to sync all of the chapters.

          • 2. Re: Long document problem
            Peter Spier Most Valuable Participant (Moderator)

            This script by Dave Saunders will break long stories into individual stories in the same file:



            //DESCRIPTION: Splits story at the selected text frame.
            // The selected frame becomes the first of the new story. 
            // Note that the behavior when an overset last frame is selected 
            // is different from that of the break-out text frame script. 
            // This script moves the overset text to the second story while 
            // breaking out the last frame leaves the overset text attached to the first story.
            if ((app.documents.length != 0) && (app.selection.length != 0)) {
                 var myFrame = app.selection[0];
                 if (myFrame.constructor.name != "TextFrame") {
                      errorExit('Please select a text frame');
                 var myStory = myFrame.parentStory;
                 var mySplit = myFrame.textFrameIndex;
                 var myTot = myStory.textFrames.length;
                 // Because of the possibility of tables, we must always work from the back
                 var myStart = myTot - 1;
                 var myEnd = mySplit;
                 // Nothing to do if user has selected first frame.
                 if (myEnd != 0) {
                      if (myStart > myEnd) {
                           var myPrevFrame = splitMe(myStory.textFrames[myStart]);
                           for (var i = myStart; i> myEnd; i--) {
                                var myNewFrame = splitMe(myStory.textFrames[i]);
                                myPrevFrame.previousTextFrame = myNewFrame;
                                myPrevFrame = myNewFrame;
                      // Now we deal with the last frame
                      myFrame = myStory.textFrames[myEnd]
                      try {
                           myIndex = myFrame.characters[0].index;
                           stEnd = myStory.length - 1;
                           myText = myStory.texts[0].characters.itemByRange(myIndex,stEnd);
                      } catch (e) { } // Ignore; happens if last character is a table or frames are empty.
                      myNewFrame = myFrame.duplicate();
                      try{myText.remove();}catch(e){} //ignore empty frame
                      try{myPrevFrame.previousTextFrame = myNewFrame;}catch(e){} //fails if one frame only
                      //Finally, if, and only if, the split is mid-table, myStory is now overset
                      if (myStory.textFrames[-1].overflows) {
                           myTable = myStory.characters[-1].tables[0];
                           myNewTable = myNewFrame.parentStory.characters[0].tables[0];
                           myRowCount = myNewTable.rows.length;
                           myTable.rows.itemByRange(0 - myRowCount,-1).remove();
            } else {
            // +++++++ Functions Start Here +++++++++++++++++++++++
            function splitMe(myFrame) {
                 myDupeFrame = myFrame.duplicate();
                 while(myDupeFrame.contents.length > 0) {
                 return myDupeFrame;
            function errorExit(message) {
                 if (arguments.length > 0) {
                      if (app.version != 3) { beep() } // CS2 includes beep() function.
                 exit(); // CS exits with a beep; CS2 exits silently.
            // +++++++ Script Ends Here ++++++++++++++++++++++++++

            It was written for CS2, I think, but should run in any later version if put into a "Version 4.0 Scripts" subfolder of the scripts panel folder (case sensitive, but dlete the quotation marks).