Easy one for you scripting geniuses,
I’m working on a custom list for the above script to fix some of the common text issues we encounter in copy coming from our writers and wire stories. Everything was working peachy until I came to the following puzzler:
I want to change the paragraph style of a certain set of text patterns. Everything works fine if the required style is sitting in the root of the style palette, however I can’t work out how to point the script at the style if it is located in a style group.
The offending line is of the form:
//grep {findWhat:”(Smith|Jones|Thompson)”} {appliedParagraphStyle:”TX Byline”} {includeFootnotes:true, includeMasterPages:true, includeHiddenLayers:true, wholeWord:false} Ensures correct style for bylines.
The paragraph style is called “TX Byline”, and it is located in a style group named “Body Text Styles”
I’ve tried
{appliedParagraphStyle:”TX Byline (Body Text Styles)”}
{appliedParagraphStyle:”TX Byline(Body Text Styles)”}
{appliedParagraphStyle:”Body Text Styles/TX Byline”}
{appliedParagraphStyle:”Body Text Styles\TX Byline”}
{appliedParagraphStyle:”Body Text Styles:TX Byline”}
…all of which give me javascript errors.
I’m sure it’s a simple fix, but I’m afraid I’m just not familiar enough with the syntax to guess at it. Any help would be appreciated.
Thanks!
Chris