Article View: adobe.scripting.indesign
Article #14753Re: [AS] How well can ID sort?
From: Shane_Stanley
Date: Tue, 20 Jan 2004 09:27
Date: Tue, 20 Jan 2004 09:27
35 lines
2180 bytes
2180 bytes
On Jan 20, 2004, at 7:54 PM, Olav Kvern wrote: > It really depends on how you're doing the sort. If you're finding 25K > text objects and sorting them with a bubble sort, then be prepared for > a long wait. For sure. > If you're sorting 25K *strings*, then it's up to AppleScript (and I > think it would go rather quickly). There's no built-in AS sort, though. Depending on the strings, you could use "do shell script" and a Unix sort, but there are issues there with the length of the data returned (which I think can be solved by writing to a file). And that also potentially involves encoding issues of Mac Roman v Unicode, which might or might not affect your data. But if you're not doing it often, there are AS sort routines around that aren't massively slow. It sounds like a matter of minutes won't matter too much in your greater scheme of things. > Also, look around--there may be a scripting extension that does > exactly the sort of search you want. Check macscripter.net. A good place to start, although I can't think of any. Shell scripting has put a fair old dent in the scripting addition business. > Shane may also have suggestions... There have been numerous discussions on this topic over the years both on Apple's AppleScript mailing list and the Dartmouth MACSCRPT mailing list. Both are searchable, I think, and would be good places to start. -- Shane Stanley <sstanley@myriad-com.com.au>
Technical Details
Message-ID:
<DA573EA7-4B2A-11D8-B512-003065D61B90@myriad-com.com.au>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.tpinternet.pl!newsfeed01.sul.t-online.de!t-online.de!webxReferences:
<2ccf76be.-1@webx.la2eafNXanI>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f939a,cf3e32adebfcf68c X-Google-Attributes: gidf939a,public X-Google-ArrivalTime: 2004-01-20 01:37:37 PST From: Shane_Stanley@adobeforums.com Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.tpinternet.pl!newsfeed01.sul.t-online.de!t-online.de!webx Newsgroups: adobe.scripting.indesign Subject: Re: [AS] How well can ID sort? Message-ID: <DA573EA7-4B2A-11D8-B512-003065D61B90@myriad-com.com.au> Date: Tue, 20 Jan 2004 01:27:23 -0800 References: <2ccf76be.-1@webx.la2eafNXanI> Lines: 39 X-Mailer: Apple Mail (2.609) MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit