formatting a variable in VBA to change colour, underlining etc.

LOUISBUHAGIAR54

Registered User.
Local time
Today, 00:54
Joined
Mar 14, 2010
Messages
157
Hello out there,

Can I format a variable in VBA ? I am including a variable which is picked up in a Dim statement and later use it as 'title' in a Message Box in the same procedure.

How do I go about change the format of how the variable appears on the 'title' part of the Message Box. ?

Many thanks for your assistance.


Louis Buhagiar
 
No you cannot. Certain objects allow formatting options and others do not, you can't really change the format of a title bar to say make it italicized or bold. Now you could make your own form that has a combination of labels, make that form popup and modal, and achieve a similar effect to a message box but in that case you can change the format of a label to italic or bold.
 
Many thanks for your information. Good to know.

However, message boxes are so convenient and easy to use that it is to much of a hasle to create a new form just to format a title bar.

In my case it is worth going that far !!

Many thanks. I will remember.

Louis Buhagiar
 
Louis,
Take a look in the Code Repository. I saw a couple of posts in there about Bold Message and MyMsgBox that may be of some help to you.
If you browse enough, you can find just about anything you need on here.
Good luck. :)
Don
 

Users who are viewing this thread

Back
Top Bottom