Reputation: 12093
I am using a pretty long StringFormat
for my bound tooltip and am currenly trying to make it multiline in XAML.
While I was able to make literal ToolTip multiline using 

for line breaks I am unable to get it to work with StringFormat
.
I am trying to get following code to give me a tooltip with line break:
ToolTipService.Tooltip= {Binding Property,StringFormat='FORMAT WITH LINE BREAK {0}'}
Upvotes: 0
Views: 1541
Reputation: 93601
In string format output, have you tried using \r instead to insert carriage returns?
The only reason these encodings exist is to allow special character values to be placed in XML/Xaml.
The 

is just an encoding for hex character A = decimal 10 = \r (carriage return).
Another one of interest is 
which is character D = decimal 13 = \n (newline).
Note Hex encoding normally requires pairs of digits so 
was the actual error.
Upvotes: 3
Reputation: 12093
Actually I got correct answer here:
official silverlight forums link
We can use 

for line break.
or :
<TextBox Text="{Binding Path=a,
StringFormat='First Line \{0\} 
 Second Line'}" />
Difference is pretty big.. This one works.
Upvotes: 3