Skip to main content
Participant
April 29, 2022
Question

Extend Script to delete unused master pages in book

  • April 29, 2022
  • 1 reply
  • 118 views

Hi,

Please suggest me on how to develop the script to delete unused master pages from all files in a book.

Thanks...

    This topic has been closed for replies.

    1 reply

    frameexpert
    Community Expert
    Community Expert
    April 29, 2022

    My DeleteFormats script has this feature. Here is basically how you do it:

    1. Loop through all of the body pages in the document. For each page, check which master page is applied and add the master page name to an array.
    2. Loop through all of the master pages. For each page, check the array to see if it is in use. If not, delete it.

     

    If you make a $50 donation to the Ride for Roswell, I will give you the source code for the script. Otherwise, you can buy the script without the source code for $29. Here are the links:

    http://give.roswellpark.org/goto/rickquatro

    http://www.frameexpert.com/store

     

    If you decide to donate, don't purchase the script from my site; I will email it to you directly. Thanks.