• 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: Two Acrobat Scripting Questions
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Two Acrobat Scripting Questions


  • Subject: Re: Two Acrobat Scripting Questions
  • From: Shane Stanley <email@hidden>
  • Date: Thu, 18 Oct 2001 08:53:48 +1000

On 18/10/01 3:18 AM +1000, Steve Thompson, email@hidden, wrote:

> In the Acrobat 5 dictionary, there is a command "Execute reference - the
> menu item to execute"
>
> However, this script
>
> on open these_items
> repeat with i from 1 to the count of these_items
> set this_item to item i of these_items
> set the item_info to info for this_item
> if (folder of the item_info is false) and ,
> (alias of the item_info is false) and ,
> (the file type of the item_info contains "PDF") then
> process_item(this_item)
> end if
> end repeat
> end open
>
> on process_item(this_item)
> tell application "Acrobat 5.0"
> activate
> open this_item
> execute "Rotate Clockwise"
> save document this_item to file (this_item+".eps") using conversion 5
> end tell
> end process_item
>
>
> Produces the message "Rotate Clockwise doesn't understand the execute
> message". Anyone tell me the correct way to refer to a menu item in Acrobat
> or where I might find it?

Probably:

execute menu item x of menu y

But you'd probably be better off looping through the pages and setting their
rotation:

tell application "Acrobat 5.0"
tell document docname
set pageCount to count each page
repeat with i from 1 to pageCount
set rotation of page i to 90
end repeat
end tell
end tell

>
> Also, in the command Using Conversion, which conversion is "PostScript
> File"? Every number I've tried (1- 8 so far) seems to save as anything but.
> Any clues?

It's conversion 4. Are you doing an activate first? This works for me:

tell application "Acrobat 5.0"
activate
save document docname to "Macintosh HD:Test.ps" using conversion 4
end tell

--
Shane Stanley, email@hidden


References: 
 >Two Acrobat Scripting Questions (From: Steve Thompson <email@hidden>)

  • Prev by Date: Re: Combining QuarkXpress Documents
  • Next by Date: Re: To Script, or not to Script?
  • Previous by thread: Two Acrobat Scripting Questions
  • Next by thread: Two Acrobat Scripting questions
  • Index(es):
    • Date
    • Thread