Change font - received messages

R

Robbie

I have a friend who keeps sending me messages in tiny
fonts that I can't read in my Outlook 2000. So I'm trying
to write a macro that I can use on an opened, received
message that selects the message, then selects all the
text and then changes it to a specific font (Times new
Roman 12) - i.e. plain text, not HTML or anything fancy.
I've done VBA in Word and Excel, but not Outlook, so I
haven't the foggiest idea where to begin, except:
Sub ChangeFont()
End Sub

Any suggestions welcomed.
Thanks in advance
 
E

Eric Legault [MVP - Outlook]

The only option you have here is to change the font size, since you can't
change the font or other font properties in a plain text message.
Dim objCBC As Office.CommandBarControl

Set objCBC = ActiveInspector.CommandBars.FindControl(, 5566)
objCBC.Execute

These are the IDs of the entries in the View -> Text Size menu:

Largest: 5566
Larger: 5567
Medium: 5568
Smaller: 5569
Smallest: 5570

If you want to work with font properties of a rich text message, you could
use the SafeInspector object from the Redemption library - http://www.dimastr.com/redemption/.

Eric Legault - B.A, MCP, MCSD, Outlook MVP
 
R

Robbie

Thanks Eric, but these are the menu steps which I want to
do programatically. They are a little different to your
suggestion (Also The Redemption library would seem to be
going over the top.)

Edit|Edit Message (in the open windo of a received message)
If text is plain text, change to Rich Text: Format|Rich
Text (or HTML)
If not, continue
Select All Text - Ctrl+A or Edit|Select All
Format Font - Times New Roman 12

Regards
Robbie
 
E

Eric Legault [MVP - Outlook]

Using Redemption may be over the top, but it will solve your problem.
There are no programmable ways to do what you want otherwise, except SendKeys
(but that's usually an exercise in frustration).

Eric Legault - B.A, MCP, MCSD, Outlook MVP
 
R

Robbie

Thanks for your help, Eric. What a pity.
No wonder people hate Microsoft! If their stupid programs
don't allow one to do something as simple as that, then
all I can say is that Visual Basic and Outlook are both
F***ing useless!
Robbie
 
E

Eric Legault [MVP - Outlook]

Another alternative is, assuming that the message is in Rich Text format and
you use WordMail as your editor, is to format the text using Word's Document
object.

See this link for more info:
http://www.outlookcode.com/d/formatmsg.htm#wordmail

There are existing ways to do what you want. It may involve a little extra
work, but in most cases VBA is quite powerful once you take the time to
learn it. If there are certain features you desire, make your voice heard
by sending an e-mail to [email protected].

Please abstain from using profanity in this forum.
 
Top