• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 9402
  • 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#?

Thanks
0
Abu Hamdan
Asked:
Abu Hamdan
2 Solutions
 
slado2Commented:
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.
0
 
jonorossiCommented:
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.

http://www.codeproject.com/useritems/A_Custom_Message_Box.asp
http://www.codeproject.com/useritems/Custom_Message_2.asp
0
 
Abu HamdanEnterprise Architect, PM ExpertAuthor Commented:
Hi,

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>.

0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
m_tawfickCommented:
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
0
 
slado2Commented:
You can use rich text edit, set it to read-only.
0
 
Abu HamdanEnterprise Architect, PM ExpertAuthor Commented:
Is there a way in rich text edit to display some portion of text as bold? and how?
0
 
slado2Commented:
Place richtextbox on you form and assign rtf property:
richTextBox1.Rtf = @"{\rtf1\ansi This is {\b bold} text}"
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

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