Re: Scripting Hyperlink changes in InDesign 2.0
Re: Scripting Hyperlink changes in InDesign 2.0
- Subject: Re: Scripting Hyperlink changes in InDesign 2.0
- From: Jeff Shapiro <email@hidden>
- Date: Thu, 11 Apr 2002 00:41:11 -0600
On 4/10/02 11:49 PM, "Shane Stanley" <email@hidden> wrote:
>
On 11/4/02 3:13 PM +1000, Jeff Shapiro, email@hidden, wrote:
>
>
> I've been trying to find a way using AS that will let me select the text of
>
> the hyperlink and change it's character style.
>
>
Why bother selecting them?
'Cause I don't know any better. :-)
>
tell application "InDesign 2.0"
>
tell document 1
>
set theStyle to character style "Link" -- or whatever
>
>
set theLinkClasses to class of source of hyperlinks
>
repeat with i from 1 to count theLinkClasses
>
if item i of theLinkClasses = hyperlink text source then
>
set applied character style of source text of source of hyperlink i to
>
theStyle
>
end if
>
end repeat
>
end tell
>
end tell
Thanks!!!!!!!! This did the trick. See, I *knew* it should be easy. I did
make minor modifications so that only URL destinations are changed. I
suppose I could do another style for all other destination types.
Thanks again.
---
Jeff Shapiro
Photography and Graphic Design
719.330.8333
Colorado Springs, CO
http://www.nensha.com |||||
mailto:email@hidden
(nensha -- Japanese -- spirit photography)
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.