This is a migrated thread and some comments may be shown as answers.
Caption Font
5 Answers 47 Views
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
DP
Top achievements
Rank 1
DP asked on 04 Aug 2008, 08:41 AM
In ExplorerBarStyle RadPanelBar I am trying to set the font of RadPanelBarGroupElement(s) caption to Bold and underlined. I can't find where to set this at design time. So I am doing it at run time as follows:

RadPanelBarGroupElement1.GetCaptionElement().Font =

New Font(RadPanelBarGroupElement1.GetCaptionElement().Font.FontFamily, 14, FontStyle.Bold)

However, I can set the font style to either Bold or Underline but not both.

What is the best way to set the font?

Thanks ... DP

5 Answers, 1 is accepted

Sort by
0
Boyko Markov
Telerik team
answered on 04 Aug 2008, 11:17 AM
Hello DP,

Thank you for writing me.

The way you currently set the font works fine and that's the way you should use.

If you have any other questions please write me back.

All the best,
Boyko Markov
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
DP
Top achievements
Rank 1
answered on 04 Aug 2008, 11:51 PM
Dear Boyko,

Thankyou for you your quick response.

My question was - how do I set the font bold as well as underlined.

I am able to do either bold or under lined.

Thanks ... DP
0
Boyko Markov
Telerik team
answered on 06 Aug 2008, 01:41 PM
Hello DP,

Here is a sample code to achieve your goal:

radPanelBarGroupElement1.GetCaptionElement().Font =
new Font(radPanelBarGroupElement1.GetCaptionElement().Font.FontFamily, 14, FontStyle.Bold | FontStyle.Underline);


I hope this helps.

All the best,
Boyko Markov
the Telerik team

P.S. We are starting work on a major upgrade of the Visual Style Builder application for the WinForms Controls and we need your help! Please, take a moment to take the survey - we won’t forget your points. You can read more on the initiative here.


Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
DP
Top achievements
Rank 1
answered on 06 Aug 2008, 11:53 PM
Thanks again Boyko.

VB.net does not like "|" says invalid character ( it may be right for C#)..

What is the separator for VB?

Regards ... DP
0
Boyko Markov
Telerik team
answered on 08 Aug 2008, 12:22 PM
Hi DP,

The code in VB should look like the one below:

radPanelBarGroupElement1.GetCaptionElement().Font = New Font(radPanelBarGroupElement1.GetCaptionElement().Font.FontFamily, 14, FontStyle.Bold Or FontStyle.Underline)

To convert code from C# to VB you can use  the following converter:

http://converter.telerik.com/batch.aspx

Sincerely yours,
Boyko Markov
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Asked by
DP
Top achievements
Rank 1
Answers by
Boyko Markov
Telerik team
DP
Top achievements
Rank 1
Share this question
or