RE: Feature request to solve a problematic AppleScript behavior with raw Apple Event codes
RE: Feature request to solve a problematic AppleScript behavior with raw Apple Event codes
- Subject: RE: Feature request to solve a problematic AppleScript behavior with raw Apple Event codes
- From: Scott Babcock <email@hidden>
- Date: Fri, 22 Oct 2010 00:32:38 +0000
- Thread-topic: Feature request to solve a problematic AppleScript behavior with raw Apple Event codes
That's an approach that I hadn't considered, but it's even more obtuse than the string-based workarounds I presented.
Also, this doesn't address the case where a property's name is one of the affected raw codes (e.g. - <<class from>>).
-----Original Message-----
Date: Fri, 22 Oct 2010 09:35:25 +1100
From: Shane Stanley <email@hidden>
Subject: Re: Feature request to solve a problematic AppleScript
behavior with raw Apple Event codes
To: AS users <email@hidden>
Message-ID: <C8E70B5D.67910%email@hidden>
Content-Type: text/plain; charset="ISO-8859-1"
Can you not compare with known reference types? Something like:
tell application "System Events"
set namedRef to fonts folder -- named
set idRef to disk 1 -- id
set procRef to process "Finder" of application "System Events"
set refRecord to procRef as record
if ?class form? of refRecord = ?class form? of (namedRef as record) then
-- named
else if ?class form? of refRecord = ?class form? of (idRef as record)
then
-- id
else
-- etc
end if
end tell
--
Shane Stanley <email@hidden>
_______________________________________________
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