Reply To: Create hyperlinks from character style

#61167

Here you go.

app.findTextPreferences = null;
app.findTextPreferences.appliedCharacterStyle = app.activeDocument.characterStyles.item(“Product Code”);
sourcelist = app.activeDocument.findText().reverse();
while (sourcelist.length > 0)
{
url = sourcelist.pop();
app.activeDocument.hyperlinks.add(app.activeDocument.hyperlinkTextSources.add(url), app.activeDocument.hyperlinkURLDestinations.add(“www.”+url.contents+”.com”));
}

This article was last modified on November 28, 2011

Comments (0)

Loading comments...