How to apply a master to a InDesign page using AS

I have been trying to find a book or whatever resource where I could find out some basic InDesign AppleScript -functions - but no luck.

I’m trying to find out the functions to do a simple “pagination” using AppleScript

  • open a library
  • delete all elements on page 1 of this document
  • apply an existing master “2-frontpage” to page one of this document
  • copy an entry in the library file to position x,y onto page 1
  • save the document to a named file

Especially the functions I could use to apply a master and to copy an element from the library to a specified (x,y) coordinate would help me a lot

Have any of you found a good book on the subject?



Try buying this book:

Appling a master page:

tell application "Indesign CS"
tell document 1
set theRef to master spread "A-Master"
tell page 1
set properties to {applied master:theRef} -- apply master spread
end tell
end tell
end tell



This is a resource that I have also found very helpful.