Quantcast
Channel: Adobe Community : Popular Discussions - InDesign Scripting
Viewing all articles
Browse latest Browse all 15932

How to add para styles in mychange

$
0
0

Hi All,

 

In the below coding is lots of find and change. Now I need to mychange one more additional change with S2, i.e. applied one of the paragraph style. Please advice and see below my coding.

 

 

 

var myfind = ["(<display>)(.+)(</display>)", "(<verse>)(.+)(</verse>)"]


var mychange = ["$2", "$2"]


for (k=0; k<myfind.length; k++)
{    app.findGrepPreferences = app.changeGrepPreferences = null;    app.findChangeGrepOptions.includeMasterPages = false;    app.findGrepPreferences.findWhat = myfind[k];    app.changeGrepPreferences.changeTo = mychange[k];    app.activeDocument.changeGrep();
}

 

 

Regards,

Vetha


Viewing all articles
Browse latest Browse all 15932

Trending Articles