Hi,
I am new to applescript and I am trying to write a simple hard coded applescript to move all read messages that are 3 days or older from one of my inboxes to a different mailbox. My hosted inbox is quite small, so I need to move things out on a regular basis.
Here is my script so far:
set _3_days_ago to (current date) - (3 * days)
tell application "Mail"
# Inbox for Exchange
set _msg_list to (every message of "Inbox:Exchange" whose read status is true and date received is before _3_days_ago)
if (_msg_list's length > 0) then
move _msg_list to mailbox "Local Inbox"
end if
end tell
I am getting an error of
error “Can’t get every message of "Inbox:Exchange".” number -1728 from every «class mssg» of “Inbox:Exchange”
I am not sure what to do to address this error.
Looking for ideas, suggestions or other ways to fix/improve this.
Using Mail v4.5 on MacOS X 10.6.7
Thanks in advance,
Mark