Из-за номера страницы это может быть не идеальным решением. Но вот какое решение я придумал, используя сценарии:
Загрузите этот образец файла и сохраните его в своей системе. Это IDML от CS5, поэтому он должен работать с CS4 +.
На страницах 3 и 4 вы заметите, что есть большой розовый блок текста с надписью ПРОЕКТ:

Если вы подтяните Script Labelпанель ( Window> Utilities> Script Label), вы увидите , что он обозначен как «DRAFT_LABEL».
Теперь возьмите следующий скрипт, скопируйте / вставьте его в текстовый редактор и сохраните его в своем каталоге Scripts (как файл .js или .jsx, не имеет значения):
try // to get the path of the file that's active when you run the script.
{
var OpenFilePath = app.documents.item(0).fullName; // Declare a variable representing the open document.
var OpenFile = app.open(File(OpenFilePath), true, 1332757360); // Create a duplicate to work with. In Adobe's world, "1332757360" means "open a copy".
}
catch (err)
{
var OpenFile = "error";
alert("Please save this file before using the script.");
}
var OpenFileLength = OpenFile.pages.length; // Get number of pages of open document and master file.
// These help make the array that stores master markers.
var ArrayCounter = 0;
var FindTheMarkers = new Array();
for (var i=0; i<OpenFileLength; i++) // Loop through every page.
{
ItemsOnPage = OpenFile.pages.item(i).pageItems.length; // Get the number of items on the page.
for (var j=0; j<ItemsOnPage; j++) // Loop through every item.
{
var ScriptLabel = OpenFile.pages.item(i).pageItems.item(j).label;
if (ScriptLabel != "" && ScriptLabel.indexOf("DRAFT_LABEL") == 0) // If the item has a label and it equals what we want it to,
{
FindTheMarkers[ArrayCounter] = i; // Put the page number in the array.
ArrayCounter++; // Advance the counter for next time!
}
}
}
var numberToSubtract = 0; // This compensates for screwing up the page counter when you remove a page.
for (i=0; i<FindTheMarkers.length; i++) // Loop through the array and remove pages!
{
OpenFile.pages.item(FindTheMarkers[i] - numberToSubtract).remove();
numberToSubtract++;
}
Перед запуском скрипта сохраните документ . Тогда беги!
Я дизайнер, который пишет сценарии, а не наоборот, так что это может быть не самый элегантный код. Но он сканирует документ на наличие элементов страницы с тегом «DRAFT_LABEL», а затем сохраняет этот номер страницы в массиве. После завершения сканирования удаляются соответствующие страницы.
Затем у вас остается новый файл с удаленными черновыми страницами!