Quantcast
Channel: Adobe Community: Message List - FrameMaker Scripting
Viewing all articles
Browse latest Browse all 3715

Re: Finding text with RegEx

$
0
0

Hi Rick,

 

Anything that uses the "\1" etc operators in the replace method does not give anything but whitespaces where the match results should be. I have in fact tried to reproduce the example from Adobe's Javascript Tools Guide that was written for the Creative Suite 5. Page 26 shows the following:

 

In a replace operation, you can use the captured regions of a match in the replacement expression by using the placeholders \1 through \9, where \1 refers to the first captured region, \2 to the second, and so on.

For example, if the search string is Fred\([1-9]\)XXX and the replace string is Sam\1YYY, when applied to Fred2XXX the search generates Sam2YYY.

 

Well, it doesn't. Look for extendscript regular expressions in the general Adobe forum and you will find at least two posts mentioning this as a bug in ESTK.

 

Ciao

 

Jang


Viewing all articles
Browse latest Browse all 3715

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>