🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: adobe.scripting.indesign
Article #8543

find+change in footnotes

#8543
From: Klaus Boer
Date: Thu, 12 Oct 2006 20:58
22 lines
1654 bytes
hallo,
I am new and a Scripting beginner. I tried find+change "-" -> "--" 
between numbers by the following script:

app.findPreferences = NothingEnum.nothing;
app.changePreferences = NothingEnum.nothing;
var txt = '';
for( i = 0; i < app.activeDocument.stories.length; i++ )
     txt = txt + app.activeDocument.stories[i].contents + ' ';
var re = /[0-9]-[0-9]/g;
var SearchTextArray = txt.match( re );
for( i = 0; i < SearchTextArray.length; i++ )
app.activeDocument.search( SearchTextArray[i], false, false, 
SearchTextArray[i].replace(/-/g,'^=') );

the script find and changes all "-" in the main text, but does not in 
the footnotes.

How to manage the find+search within maintext and footnotes???

Thanks for help.
Klaus
Technical Details
Message-ID: <egma2i$7p7$1@online.de>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!news2.volia.net!npeer.de.kpn-eurorings.net!feed.news.schlund.de!schlund.de!news.online.de!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: f939a,2c9d8a6a31dede5c,start
X-Google-Attributes: gidf939a,public
X-Google-Language: ENGLISH,ASCII-7-bit
Path: arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!news2.volia.net!npeer.de.kpn-eurorings.net!feed.news.schlund.de!schlund.de!news.online.de!not-for-mail
From: Klaus Boer <klaus.boer@onlinehome.de>
Newsgroups: adobe.scripting.indesign
Subject: find+change in footnotes
Date: Thu, 12 Oct 2006 22:58:52 +0200
Organization: 1&1 Internet AG
Lines: 22
Message-ID: <egma2i$7p7$1@online.de>
NNTP-Posting-Host: mnch-d9b860d9.pool.mediaways.net
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding: 7bit
X-Trace: online.de 1160686482 7975 217.184.96.217 (12 Oct 2006 20:54:42 GMT)
X-Complaints-To: abuse@einsundeins.com
NNTP-Posting-Date: Thu, 12 Oct 2006 20:54:42 +0000 (UTC)
User-Agent: Thunderbird 1.5.0.7 (Windows/20060909)