🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: adobe.scripting.indesign
Article #1569

Re: text replace and SpecialCharacters

#1569
From: Olav_Kvern
Date: Fri, 30 Jan 2009 19:28
15 lines
1420 bytes
Hi Siegfried,

re:

app.changeGrepPreferences.changeTo = SpecialCharacters.FORCED_LINE_BREAK;

...won't work, because you don't enter a forced line break in the Find What field of the Find/Change panel. Instead, you enter a metacharacter--so you also use a metacharacter when you perform the task from scripting. This is what jongware's saying (thanks jongware!), but I thought I'd expand on it a bit.

In short: Don't use special characters enumerations in Find/Change. Sometimes, it'll work (when the characters are visible, non-control characters), sometimes it won't.

Other than the need to enter escape characters (to produce valid JavaScript strings), The Find What and Change To properties of all of the find/change preferences objects exactly mimic the corresponding fields in the Find/Change panel.

Thanks,

Ole
Technical Details
Message-ID: <59b7bb64.2@webcrossing.la2eafNXanI>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!newshub.sdsu.edu!webcrossing
References: <59b7bb64.-1@webcrossing.la2eafNXanI>

Show Full Headers
Complete Article Headers
X-Google-Thread: f939a,e76ee089cd705fa3
X-Google-Attributes: gidf939a,domainid0,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
From: Olav_Kvern@adobeforums.com
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!newshub.sdsu.edu!webcrossing
Newsgroups: adobe.scripting.indesign
Subject: Re: text replace and SpecialCharacters
Message-ID: <59b7bb64.2@webcrossing.la2eafNXanI>
Date: Fri, 30 Jan 2009 11:28:52 -0800
References: <59b7bb64.-1@webcrossing.la2eafNXanI>
Lines: 22
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit