Ask a Question related to Adobe Indesign Windows, Design and Development.
-
Steve_Dorsey@adobeforums.com #1
How di I use scripts?
I found a great paginating script, but I have no idea how to use it.
Thanks (script below)
myPages = app.documents[0].pages;
// Let's make sure that the pages are a multiple of four
app.documents[0].documentPreferences.allowPageShuffle = false;
if (myPages.length % 4 != 0) {
alert("Document length isn't a multiple of four.");
exit();
}
for (i=0; myPages.length>i; i++) {
origSection = myPages[i].appliedSection;
origNumbering = origSection.pageNumberStyle;
origSection.pageNumberStyle = PageNumberStyle.arabic;
pageName = myPages[i].name;
sectName = origSection.name;
if (sectName != "") {
pageName = pageName.split(sectName)[1];
}
pageNo = Number(pageName);
newSection = app.documents[0].sections.add(undefined, undefined, {pageStart:app.documents[0].pages[i], continueNumbering:false, pageNumberStart:pageNo, pageNumberStyle:origNumbering});
origSection.pageNumberStyle = origNumbering;
}
app.documents[0].documentPreferences.allowPageShuffle = true;
for (i=0; (myPages.length/2)>i; i++){
if (i % 2 == 0) {
app.documents[0].pages[myPages.length - 1].move(LocationOptions.before,app.documents[0].pages[i*2],BindingOptions.leftAlign);
} else {
app.documents[0].pages[myPages.length - 1].move(LocationOptions.after,app.documents[0].pages[i*2],BindingOptions.rightAlign);
}
}
Steve_Dorsey@adobeforums.com Guest
-
php scripts
Does anyone know of like some customizeable script that allows me to have one icon if there is a user logged in and another if nobody the user is not... -
CS: Scripts do not appear in Scripts menu
I have several utility AppleScripts that I created for Illustrator 10. I'd like to use these in CS, and they work correctly when I choose "Browse"... -
Where should PHP scripts go?
Hi folks, In developing a website containing both HTML files and PHP files, I had thought that it was good practice (or even mandatory depending... -
scripts that control other scripts
Is there any behaviour script that when attached to a sprite can control the functionality of any other scripts attached to that sprite? I want to... -
ASP scripts from IIS 4 to IIS 5
> Set objLog = objFile.OpenTextFile(Server.MapPath Do you have the Norton and/or McAfee Viruses (err, anti-virus products) installed?... -
Stu_Bloom@adobeforums.com #2
Re: How di I use scripts?
Since this is a javascript script, save it as a plain text file with the extension .js in your scripts directory, which is almost certainly C:\Program Files\Adobe\InDesign CS\Presets\Scripts. Open the Scripps palette (Window->Scripting->Scripts. The filename you saved the script under should be there. Double-click on that filename.
Stu_Bloom@adobeforums.com Guest
-
Dave_Saunders@adobeforums.com #3
Re: How di I use scripts?
Stu's advice on how to activate a JavaScript script posted like this in the forums is right on.
In the case of this particular script, please also note the advice posted here: Dave Saunders "InDesign won't impose pages!?!" 5/5/04 10:21am </cgi-bin/webx?14@@.3bb3c172/6>
The key points are:
1. Work on a copy of your document.
2. Be sure to activate the Spreads option in the print dialogs when printing (or exporting to PDF) the document that this script generates from your original.
Dave
Dave_Saunders@adobeforums.com Guest



Reply With Quote

