🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: adobe.scripting.indesign
Article #1787

Re: [CS4 JS] Scripting Indexes

#1787
From: Peter Kahrel
Date: Mon, 26 Jan 2009 22:02
13 lines
1008 bytes
At each iteration the script asks InDesign to create an array of topics, so maybe you could speed things up a bit by going about it like this:

topics = app.activeDocument.indexes[0].allTopics; 
topics_length = topics.length; 
for (var i=0; i < topics_length; i++) {  
  $.writeln(i+' '+topics[i].name);  
}



As there are so many topics, this could make a difference.

Peter
Technical Details
Message-ID: <59b7ae01.0@webcrossing.la2eafNXanI>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news2.google.com!news.glorb.com!news2.glorb.com!newshub.sdsu.edu!webcrossing
References: <59b7ae01.-1@webcrossing.la2eafNXanI>

Show Full Headers
Complete Article Headers
X-Google-Thread: f939a,6b07b633d95c342d
X-Google-Attributes: gidf939a,domainid0,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Peter Kahrel" <kahrel@kahrel.plus.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news2.google.com!news.glorb.com!news2.glorb.com!newshub.sdsu.edu!webcrossing
Newsgroups: adobe.scripting.indesign
Subject: Re: [CS4 JS] Scripting Indexes
Message-ID: <59b7ae01.0@webcrossing.la2eafNXanI>
Date: Mon, 26 Jan 2009 14:02:00 -0800
References: <59b7ae01.-1@webcrossing.la2eafNXanI>
Lines: 11
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit