20 Replies Latest reply on Jan 27, 2012 5:52 AM by natdeamer

    Script - Paste a TextFrame into a TextFrame

    natdeamer

      Hi,

       

      I am very new to Indesign Scripting (1 week?).  Getting stuck trying to Paste a TextFrame inside another TextFrame.  I can do it in the UI and successfully wrote a script to do this:

       

      app.select(someTextFrame);

      app.copy();

      app.select(pasteIntoTextFrame.insertionPoints[0]);

      app.paste();

       

      Where someTextFrame is the TextFrame I am trying to copy into the PasteIntoTextFrame....

       

      But, this doesn't work on InDesign Server.

       

      Example / Reason: TextFrame1 willl be centered, Then TextFrame2 will be aligned right, TextFrame3 centered, TextFrame4 aligned right. 

      Then all of these are pasted into the 'Master' text frame with its own alignment options

       

      Hopefully the diagram will help explain my poor description.

      sample.png

      Can anyone point me in the right direction? Thanks