Article View: adobe.scripting.indesign
Article #15465Re: [Help] "Can't get character 1 of..." error
From: Shane_Stanley
Date: Wed, 03 Dec 2003 20:58
Date: Wed, 03 Dec 2003 20:58
17 lines
1362 bytes
1362 bytes
The way you refer to ranges of text has changed completely in CS, and now matches the "normal" AppleScript method. So asking for "characters x thru y" returns a list, and to extract a string you use "text from character x to character y". The good news with this is that ranges can be described by other than characters -- "text from character 1 to word 3 of paragraph 5", for example. > set KernTextBefore to object reference of characters (fSlash - 1) > through fSlash of PStory Try: set KernTextBefore to object reference of text from character (fSlash - 1) to character fSlash of PStory -- Shane Stanley <sstanley@myriad-com.com.au>
Technical Details
Message-ID:
<824B7A64-25D3-11D8-9DE9-003065D61B90@myriad-com.com.au>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!fu-berlin.de!newsfeed01.sul.t-online.de!t-online.de!webxReferences:
<2cceb626.-1@webx.la2eafNXanI>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f939a,bd2e54fcae72c1c9 X-Google-Attributes: gidf939a,public X-Google-ArrivalTime: 2003-12-03 13:08:01 PST From: Shane_Stanley@adobeforums.com Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!fu-berlin.de!newsfeed01.sul.t-online.de!t-online.de!webx Newsgroups: adobe.scripting.indesign Subject: Re: [Help] "Can't get character 1 of..." error Message-ID: <824B7A64-25D3-11D8-9DE9-003065D61B90@myriad-com.com.au> Date: Wed, 3 Dec 2003 12:58:56 -0800 References: <2cceb626.-1@webx.la2eafNXanI> Lines: 21 X-Mailer: Apple Mail (2.606) MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit