Skip navigation
Currently Being Moderated

Using FindChange to control paragraph rules

May 11, 2012 10:50 AM

Is there a way to turn ruleAbove/ruleBelow on and off using the FindChangeByList script?

 

If the active paragraph style has a ruleBelow defined but turned off, it seems I should be able to turn it on with a statement like this in the FindChangeList.txt file:

 

grep     {findWhat:"(some unique string)"}     {ruleBelow:true,changeTo:"$1"}     {}   

 

This does not throw an error, but it doesn't work for me.  None of the paragraph rule properties can be applied: offset, line weight, etc.

 
Replies
  • John Hawkinson
    5,514 posts
    Jun 25, 2009
    Currently Being Moderated
    May 11, 2012 10:56 AM   in reply to rick_schwein

    Which version of the script (JS, AS, VB) are you using?

     
    |
    Mark as:
  • Currently Being Moderated
    May 11, 2012 7:26 PM   in reply to rick_schwein

    Indeed, it can't be done directly with a findGrep (or findChange). Look at the dialog box in InDesign and you'll see that the paragraph rules are not included. Since the JS Find features leverage the technology that provides the find features to the interactive user, it suffers from the same limitation.

     

    In a script, you can get around this by doing the find (rather than a change) and then iterate through the results setting the paragraph rule you want.

     

    Dave

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points