Scripting For Eudora X
Scripting For Eudora X
- Subject: Scripting For Eudora X
- From: List Kreme <email@hidden>
- Date: Sat, 19 May 2001 19:20:54 -0600
I have the following script snippet that works perfectly in OS 9 with
Eudora 4 or 5 and fails with Eudora X under OS X. The variable TheBox
contains the name of the current mailbox (e.g. "In") and the constant
BackupMailbox contains the name of a top level mailbox (e.g. "Backups").
TheCount is simply the count of every message in mailbox TheBox.
The script goes along executing until it reaches a message that satisfies
the interior IF (an old message, in other words) then the script simply
blows up. the event log follows the code snippet.
-- Apple script Code
-- Each lines end with a -- comment string
repeat with CurrentM from TheCount to 1 by -1 --
try --
set TheMessage to (a reference to message CurrentM of mailbox TheBox) --
set MessageDate to universal seconds of TheMessage --
if MessageDate is less than or equal to MessageAge then --
set NumberRemoved to NumberRemoved + 1 --
move message CurrentM of mailbox TheBox to end of mailbox
BackupMailbox --
end if --
on error errormsg --
--> do some vairable collecting and display the values. --
end try --
end repeat --
(*
Event Log:
get universal seconds of message 234 of mailbox "In"
--> date "Tuesday, 24 April 2001 17:30:04"
move message 234 of mailbox "In" to mailbox "Backups"
-- That's the command that fails. Yes Backups exists, and at the top level.
-- As I said, it works under OS 9.1, 9.04, and all variants of 8.
end tell
tell current application
display dialog "Error Trap 1b
CurrentM: 234 -- The current message number
Box: In --0 The mailbox being processed
Message Date: Tuesday, 24 April 2001 17:30:04 -- The date of the message
Age: Tuesday, 24 April 2001 19:04:37 -- The test date
MsgNum: 328 -- The total number of messages int he mailbox
Backups -- The name of the BackupMailbox
errmsg: Eudora 5.1 (OS X) got an error: Some parameter is missing for move
The actual error message returned.
*)
That's it. I don't know what the problem is. I know I can do:
move message 1 of mailbox 1 to end of mailbox 3
move message 1 of mailbox "In" to end of mailbox "Trash"
move message 1 of mailbox 1 to end of mailbox "Trash"
move message 1 of mailbox "In" to end of mailbox 3
But nothing involving a non-built-in mailbox seems to work.
Am I missing something, or is there something wrong with Eudora for OS X?
--