Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have users sending mail through Outlook which formats the text as Rich text. I'm trying to create script where a "catch-all" email address intercepts the email, converts it to plain text then send it to the user. I've got the Re-Direct working with some searching around, however the message body is still Rich Text. Is there a way I can modify the script below to achieve this:

tell application "Mail"

set AppleScript's text item delimiters to ""
set theRedirectRecipient to "intercept@mail.com"
set theRedirectSender to "Case manager"
set theMessages to the selection

repeat with thisMessage in theMessages

    tell application "Mail"

        set theRedirectedEmail to redirect thisMessage
        tell theRedirectedEmail

            if subject of thisMessage is "" then

                set subject of theRedirectedEmail to "Subject Was Empty"
            end if

            make new to recipient at beginning of to recipients with properties {address:theRedirectRecipient}
            delete bcc recipients
            delete cc recipients

        end tell

        set the sender of theRedirectedEmail to theRedirectSender
        #delay 1
        send theRedirectedEmail

    end tell

end repeat

end tell

share|improve this question

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.