InDesign: Name of Paragraph Style
InDesign: Name of Paragraph Style
- Subject: InDesign: Name of Paragraph Style
- From: David Wolfe <email@hidden>
- Date: Wed, 14 Mar 2007 18:42:20 -0400
So the next bit of my script is to rename every paragraph style to
include "SP:" at the front of its name. The code I have so far is:
repeat with i from 3 to (count of paragraph styles of active document)
tell active document
set oldName to name of paragraph style i
set name of paragraph style i to ("SP:" & oldName)
end tell
end repeat
but it seems a bit wonky. I am starting the repeat with 3 to avoid
[No Paragraph Style] and [Basic Paragraph]. The script begins
renaming paragraph styles. But as they are renamed, they are pushed
down the list alphabetically, then "reprocessed" resulting in several
of the paragraph styles in the middle of the list with new names like
"SP: SP:" and "SP: SP: SP: SP:", and some others not being renamed
because the counter runs out. Any ideas what I'm doing wrong?
Thanks for your help,
David Wolfe
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden