• macro to toggle reading in plain text (Outlook 2003)

    Home » Forums » AskWoody support » Productivity software by function » MS Outlook and email programs » macro to toggle reading in plain text (Outlook 2003)

    Author
    Topic
    #428280

    I’m using Outlook 2003 on a Windows 2000 machine. I usually prefer to read most of my email in plain text format (for virus security reasons), but sometimes its easier to read a trusted message in HTML format. When I want to do so, I have to go and turn off my Tools|Options|Email Options “Read all standard mail in plain text”. Then, when I’m done with reading the message, I usually want to turn the option back on. This gets cumbersome as you might imagine.

    What I’d like to do is create a macro that will toggle this option on and off. I’m not a programmer though and it looks like creating simple macros in Outlook 2003 requires more VBA knowledge than in Word. Could anyone help me out with the programming to set this up?

    Thanks in advance,

    Mark

    Viewing 0 reply threads
    Author
    Replies
    • #994726

      Check out this MSDN site on formatting e-mail messages… BodyFormat_Property … hope this helps… trish

      • #994797

        Thanks Trish, but it looks to me like this only works on the fomatting for new messges being composed, not for reading those I’ve already received. It did get me to looking around in some new places though and I found that in turning the option on and off the following registry key get’s toggled: HKEY_CURRENT_USERSoftwareMicrosoftOffice11.0OutlookOptionsMailReadAsPlain. (0 for HTML mail, 1 for plain text).

        I can change the registry key manually (and presumably with a macro), but it seems that something else still needs to happen to effect the change in Outlook. Any ideas on what else Outlook is doing whe toggling between plain text and HTML / RTF? Some sort of settings refresh or reload function, maybe?

        Mark

        • #994866

          (Edited by JohnBF on 16-Jan-06 16:11. )

          Do you have 2003 SP2? (I don’t.) You are supposed to be able to click on the Infobar (between the message header and body) and temporarily change the view from the Infobar with SP2.

          Outlook’s object model is not exposed the way other MS Apps are, partly because MS is afraid of Outlook being used as a SPAM and virus dissemination engine. But MS hasn’t exposed many of the Application Option settings or View settings, which can’t have anything to do with those risks, so who knows. See if http://www.Outlookcode.com[/url%5D has anything that will help you – you don’t need to sign up, look for the small search dialog on the home page.

          Edit. Here’s something simple that you can try. I assume that you would add this to the toolbar icon of your choice in the general Outlook window, since there’s not much point in it if you have already opened the message. Unfortunately, it will ask you every time if you want to save changes when you close the message window.

          Private Sub ShowPlain()
          With ActiveExplorer.Selection(1)
          If .Class = olMail Then
          .BodyFormat = olFormatPlain
          .Display
          End If
          End With
          End Sub

          • #995107

            John,

            I installed SP2 and the InfoBar is exactly what I needed. I’ve seen it before, but I don’t use it much and never noticed that it contained info about switching to an HTML view. Thank you muchly.

            Mark

    Viewing 0 reply threads
    Reply To: macro to toggle reading in plain text (Outlook 2003)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: