Formatting message boxes

stemar

Board Regular
Joined
Mar 16, 2002
Messages
248
Is there a way to get bold or italic text in a message box?

I want it to look something like this:

If you do this you must do that

Thanks in advance
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.

Andrew Poulsom

MrExcel MVP
Joined
Jul 21, 2002
Messages
73,092
Sorry, but you can't apply rich text formatting in a standard MsgBox, nor in a UserForm Label control. You could use 3 Label controls on a UserForm.
 

patrickmuldoon99

Active Member
Joined
Jun 27, 2006
Messages
345
hmmm I don't think you can using a standard msgbox

You could, however, make your own userform version of a msgbox, and have a sub procedure that calls it. You could then use any way of representing emboldened text you wish - for example you may wish to pass an optional argument stating the word you wish to be bolded. In your function, you would then have to set a control so that it would bold the supplied text.

Now I come to think of it, I believe you have to have the same typeface applied to all text within one label - though I may be wrong about that. If that is the case, it may not be so trivial to place bold text within standard text on a form
 

Scott Huish

MrExcel MVP
Joined
Mar 17, 2004
Messages
19,958
Office Version
  1. 365
  2. 2010
Platform
  1. Windows
Dominic, that takes you to a page that says this:

The topic or post you requested does not exist
 

DominicB

Well-known Member
Joined
Oct 3, 2005
Messages
1,569
Thanks for that HOTPEPPER

Dominic, that takes you to a page that says this:
The topic or post you requested does not exist:

Not any more.

DominicB
 

Forum statistics

Threads
1,136,927
Messages
5,678,621
Members
419,776
Latest member
mikelowski

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top