This is a migrated thread and some comments may be shown as answers.

Displaying '&' character in button element?

1 Answer 54 Views
Buttons, RadioButton, CheckBox, etc
This is a migrated thread and some comments may be shown as answers.
Michael
Top achievements
Rank 1
Michael asked on 30 Apr 2009, 01:14 PM
I'm attempting to create a button that says "Save & New".  However, using the normal chord for this "&&" changes the display on the button to "Save & .....".  Using just an single '&' does the normal mnemonic thing of underlining the next character. 

Note: the "..." is not because I've run out of room.  if I write "Save And New", it shows up just fine.

1 Answer, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 01 May 2009, 07:58 AM
Hi Michael,

There is an issue with the text measure when you are trying to escape ampersand character.
This will be fixed in our next version. You could avoid this behavior by setting UseMnemonic property of TextPrimitive to false:

((TextPrimitive)buttonElementInRibbon1.Children[1].Children[1]).UseMnemonic = false

Don't hesitate to contact us if you have other questions.

Best wishes,
Peter
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
Buttons, RadioButton, CheckBox, etc
Asked by
Michael
Top achievements
Rank 1
Answers by
Peter
Telerik team
Share this question
or