• 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: Script Modification
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Script Modification


  • Subject: Re: Script Modification
  • From: "email@hidden" <email@hidden>
  • Date: Sun, 16 Jan 2011 08:22:18 -0800

On Jan 16, 2011, at 6:44am, Neil Laubenthal wrote:

> tell application appName
>       activate
>       save the front document
>       close the front document
> end tell
>
> (the variable appName is used to capture the version of Acrobat you have installed).
>
> The code from the Save as script is:
>
> -- Save As code
> repeat until exists menu bar 1
> end repeat
> click the menu item "Save As..." of menu "File" of menu bar 1
> repeat until name of front window is "Save As"
> end repeat
> repeat until name of front window is not "Save As"
> end repeat
> click the menu item "Close" of menu "File" of menu bar 1
> -- end of Save As code

I don't have Acrobat installed here, but I can give you some advice.

The save as script, as you've posted it, may be missing a key element.  Is there a "Tell Application "System Events" in the script?

If there is then the script is using GUI scripting and that would be required.

If not, then the script is a method of puppeting the user interface from Adobe, which I'd seen in earlier versions of Acrobat but didn't' find very reliable.

Here's what I would try first:

tell application appName
  activate
  set newPDFpath to choose file name with prompt "Where do you want to save your new PDF?"
  -->>file "Macintosh HD:Users:edstockly:Desktop:here"

 tell the front document
   save as newPDFpath
   --save in newPDFpath
  -- Check the acrobat dictionary for the exact term
  close
end tell

If that doesn't work, let the list know and we'll find a better solution.

BTW, I'm betting that Adobe mucked with the commands for saving between various releases and Mr. Kissel used the Click commands do develop a script that would work with several releases.  The example I provided may not work with other versions of Acrobat.

ES _______________________________________________
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

  • Follow-Ups:
    • Re: Script Modification
      • From: Neil Laubenthal <email@hidden>
References: 
 >Script Modification (From: Neil Laubenthal <email@hidden>)

  • Prev by Date: Re: Top-posting [ was Variable names]
  • Next by Date: Re: Top-posting [ was Variable names]
  • Previous by thread: Script Modification
  • Next by thread: Re: Script Modification
  • Index(es):
    • Date
    • Thread