• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: CS3 Change text properties
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CS3 Change text properties


  • Subject: Re: CS3 Change text properties
  • From: Wayne Melrose <email@hidden>
  • Date: Thu, 4 Oct 2007 07:37:10 +0200


On 04/10/2007, at 5:44 AM, Wayne Melrose wrote:


On 04/10/2007, at 3:30 AM, Shane Stanley wrote:

set properties of change text preferences to {fill color:swatch "UniqueColor"}

In cases like this, and generally in InDesign, it's better to use
references:

set myColor to swatch "UniqueColor" of document 1
set properties of change text preferences to {fill color:myColor}


Thanks for the reply Shane, it was a little late when I posted that, I forgot to mention that I had tried that, and this is the error I got.. 

Adobe InDesign CS3 got an error: Request failed because object is from a different document or workspace.


I think I solved my own problem with this.. 


tell application "Adobe InDesign CS3"
set find text preferences to nothing
set change text preferences to nothing


set find what of find text preferences to "text"


tell text frame 1 of document 1
set lstFoundItems to find text
repeat with propCurrentCharacter in lstFoundItems
set fill color of propCurrentCharacter to "UniqueColor"
end repeat
end tell


set find text preferences to nothing
set change text preferences to nothing
end tell



Although I am a little confused as to why the dictionary lists a whole bunch of document properties, including Character and Paragraph styles (which work fine and are unique to a document) although a swatch that is defined by the user errors.. 

 _______________________________________________
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

References: 
 >Re: CS3 Change text properties (From: Shane Stanley <email@hidden>)
 >Re: CS3 Change text properties (From: Wayne Melrose <email@hidden>)

  • Prev by Date: Re: CS3 Change text properties
  • Next by Date: Re: Bad Characters from UnicodeŠ
  • Previous by thread: Re: CS3 Change text properties
  • Next by thread: Re: CS3 Change text properties
  • Index(es):
    • Date
    • Thread