My Entourage Spam Script

J

Jammer Six

Paul, here's the latest version. I got clever, and added a line that
deletes the spam when the script is done with it.

I can't make the finder stuff work. Doesn't a "tell..." command need an
"end tell" at the end of it?

Anyway, here's the latest copy.

I wish we could get it figured out. I hate to admit defeat.

**********
--One address or the other must be commented out.
property spamAddr : "(e-mail address removed)"
--property spamAddr : "(e-mail address removed)"

tell application "Microsoft Entourage"
set tempFolderPath to (path to MUD as Unicode text) & "Entourage
Temp:"
set currentMessages to the current messages
set src to "I have some spam to report." & return & return & "Thank
you."
set theFiles to {}
repeat with i from 1 to (count currentMessages)
set theMessage to item i of currentMessages
set theSubject to subject of theMessage -- as Unicode text
set AppleScript's text item delimiters to {":"}
set wordList to text items of theSubject
set AppleScript's text item delimiters to {"-"}
set theSubject to wordList as Unicode text

save theMessage in (tempFolderPath & theSubject) -- just the path
--tell application "Finder" to update alias tempFolderPath
tell me to set theFile to alias (tempFolderPath & theSubject)
--actual file
set end of theFiles to theFile
delete theMessage
end repeat
set AppleScript's text item delimiters to {""}

make new outgoing message at out box folder with properties ¬
{content:src, subject:"Spam report", recipient:spamAddr,
attachment:theFiles}

end tell

**********
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top