Fonts

G

Guest

I want to apply the font styles to rtb.selectionfon
I can apply one at a time, but I want to use the buttons to enable more than just one style
Ex. Bold and Italic or Bold, Italic, and Underline
 
N

Neil Knobbe

Hi Bill

If you want to get multiple styles on your Text, then you use the Or Keyword
to add extra Styles



rtb.SelectionFont = New Font(rtb.Font.Name, rtb.Font.Size, FontStyle.Bold Or
FontStyle.Italic)



Will make the selected Text both Bold and Italic



Hope this helps.



Neil Knobbe

Visual Basic MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top