At 4:12 PM -0700 8/27/2001, Michael J. Lew wrote:
>However, this Transcript fails, returning only "Got error -1708 when
>sending Apple event" in the result:
>
>put "the count of messages of mailbox " & quote & "In" & quote into myReq
>request myReq from application "Eudora"
>put it & return & the result
>
>I can successfully use the do field as applescript method in the Rev
>1.1 alpha, and will. However, I would like to understand the request
>command (and related) better.

The request command (and the send to program command) are related to
AppleScript in the sense that it's all built on Apple Events, but "request"
doesn't simply send a line of AppleScript to the recipient program.
Instead, it sends the "eval" Apple Event along with the string ("put the
count of messages..."). The eval event requests the app to evaluate the
expression given, using its own internal scripting structure (whatever that
may be - e.g. in HyperCard, HyperTalk is used). And not all applications -
not even all AppleScript-friendly ones - can handle scripting internally.

In this case, error -1708 is errAEEventNotHandled - in other words, Eudora
can't deal with the eval Apple Event it's being sent. This is why request
doesn't work with the line of AppleScript in this case.

Hope this clarifies a bit....

--
Jeanne A. E. DeVoto ~ [EMAIL PROTECTED]
http://www.runrev.com/
Runtime Revolution Limited - Power to the Developer!


Reply via email to