[Last Call] Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 8796
  • Last Modified:

Display bold fonts in MessageBox Windows c#

Hi All,

Is there a way other than creating a custom form, for displaying bold fonts in messageBox? i have to display some if the words in message box as bold,,, if No ,, then can someone guide me to free ready made controls built on windows c#?

Abu Hamdan
Abu Hamdan
2 Solutions
You can't change standard MessageBox behaviour and design. Your only chance is to write your own messagebox. Just inherit from Form and make it look and behave as you want.
These 2 articles which follow on from each other show you how to make your own custom messagebox which has all the features of the normal messagebox so it behaves very similar.

Abu HamdanEnterprise Architect, PM ExpertAuthor Commented:

The samples suggested have no ability to show text in bold,  if i am creating my own form,, what control do you suggest to be used to display the text?  how i will be able to send font like this:

Hello this is your <b>Prodcut Name</b>.

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

You cannot change this behavior of MessageBox. One solution is to derive your own MessageForm class from Form to display your message with font bold. Then call its ShowDialog method to show the form
You can use rich text edit, set it to read-only.
Abu HamdanEnterprise Architect, PM ExpertAuthor Commented:
Is there a way in rich text edit to display some portion of text as bold? and how?
Place richtextbox on you form and assign rtf property:
richTextBox1.Rtf = @"{\rtf1\ansi This is {\b bold} text}"

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now