3

I've a big problem with an export applescript. I would like to export many keynote files to powerpoint files. I found this script below, but there is an error that tells that the menu item "Exporter..." ("Export..." in English, my version is in french) doesn't exist. When I change "Exporter..." by "Fermer", it works very well!!!?

May you help me?

below the script I've written:

set thisFile to "/Users/kyou83/Documents/pépépé.key"
tell application "System Events"
    tell application "Keynote"
        activate
        open thisFile
    end tell
    tell process "Keynote"
        click menu item "Exporter..." of menu of menu bar item "Fichier" of menu bar 1
    end tell
end tell

''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' And here the error description

error "Erreur dans System Events : Il est impossible d’obtenir menu item \"Exporter...\" of menu of menu bar item \"Partage\" of menu bar 1 of process \"Keynote\"." number -1728 from menu item "Exporter..." of menu of menu bar item "Partage" of menu bar 1 of process "Keynote"

1
  • 1
    I don't have anything with Keynote installed to test, but try using the ellipsis character (…) rather than three dots.
    – robmathers
    Commented Nov 28, 2012 at 18:48

1 Answer 1

2

I cannot believe how simple the answer was. Instead of three periods, i needed to use an ellipsis character in my string.

As I use the azerty keyboard (I'm french) you have to press alt;! to generate an ellipsis.

1
  • Christophe, if this is the answer, you should mark it.
    – ThomasW
    Commented Jan 10, 2013 at 0:48

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .