Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Does the Junk filter learn from unmarked Junk?' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Does the Junk filter learn from unmarked Junk?
Authored by: kholburn on Oct 27, '06 02:49:16PM
I use this one:

using terms from application "Mail"
	on perform mail action with messages theMessages for rule theRule
		tell application "Mail"
			set theText to "This AppleScript is an AppleScript rule action" & return & return & "To view this script, hold down the option key and select it again from the Scripts menu."
			try
				-- If this is not being executed as a rule action, getting the name of theRule variable will fail.
				set theRuleName to name of theRule
				set theText to ""
			end try
			if theText is not equal to "" then
				display dialog theText buttons {"OK"} default button 1
			else
				repeat with eachMessage in theMessages
					set junk mail status of eachMessage to true
				end repeat
			end if
		end tell
	end perform mail action with messages
end using terms from



[ Reply to This | # ]