Hi guys
You’ve been very welcoming, so I venture to ask for some advice. Please be patient with my ignorance. I’m ploughing my way through some tutorials, and trying to use what I discover.
Every day SpamSieve puts most of my spam in an Apple Mail folder called Spam . I then spamcop it by forwarding each message separately. It’s very time-consuming. Just the job for AppleScript!
It should be a very simple script, since I have SpamSieve working so well, that I haven’t had any false positives for ages. What goes in that box is spam. I know my spamcop submit address. All I need is to put them together.
I think possibly I’m not defining enough: it’s hard to tell with AS. It seems to know so much about the system and the applications, that I have trouble working out what I need to define, and what I don’t.
My current effort aims to spamcop each msg in the Spam folder, then move them to the Trash mailbox. It compiles, it runs, when I select it from the Mail scripts menu, I don’t get an error msg, but I don’t get any action, either. I’m getting muddled. If you have time and inclination to offer some advice, I would very much appreciate it. Thankyou.
My script at this stage (the correct address is where I have "my spamcop address):
on run
tell application “Mail”
if message is in mailbox = “Spam” then
forward message
set address of outgoing message to “my spamcop address”
send message
delete message
repeat until number of messages in mailbox “Spam” is 0
end repeat
end if
end tell
end run