Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Keystroke in AppleScript




On 31 Mar 2007, at 15:38, KOENIG Yvan wrote:

Le 31 mars 07 à 16:23:00, kai a écrit :

On 31 Mar 2007, at 10:00, KOENIG Yvan wrote:

keystroke Escape using {command down}

I'd try something like:

----------------
tell application "System Events"
	key code 53 using command down
end tell
----------------

Thanks kai

Is the behaviour different with

key code 53 using command down

and

keystroke (ASCII character 27) using {command down}

In theory, the behaviour should generally be similar, Yvan. In practice, ASCII character 27 is less than reliable here.


As you'll also be aware, results from using key codes can be generally more dependent on keyboard layout than when using ASCII characters. However, escape is one of the keys that are less likely to move around... ;-)

---
kai


_______________________________________________ Do not post admin requests to the list. They will be ignored. AppleScript-Users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/applescript-users/email@hidden Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden
References: 
 >Keystroke in AppleScript (From: Pierre-Antoine Mangeret <email@hidden>)
 >Re: Keystroke in AppleScript (From: KOENIG Yvan <email@hidden>)
 >Re: Keystroke in AppleScript (From: kai <email@hidden>)
 >Re: Keystroke in AppleScript (From: KOENIG Yvan <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.