MultiBinding in button label?

Ribbon for WPF Forum

Posted 15 years ago by SledgeHammer01
Version: 9.2.0515
Avatar
Isn't multibinding supported by default on a Label control?

Here is my XAML. This *DOES* work at runtime. I can properly bind to the PageCount property. However, in the VS designer, I get the blue squiggly line saying "Property 'Label' does not support values of type 'MultiBinding'." While I'm only binding one thing now, I'm going to be binding the other half of the page count, so I don't want to use the string formatter obviously.

<ribbon:Button Context="StatusBarItem" Padding="6,0,6,0"
ScreenTipHeader="Page number in document. Click to open the Go To dialog box."
Command="local:ApplicationCommands.ShowDialog" CommandParameter="GoTo">
<ribbon:Button.Label>
<MultiBinding StringFormat="Page: 1 of {0}">
<Binding ElementName="mainWindow" Path="TIFFDocument.PageCount" />
</MultiBinding>
</ribbon:Button.Label>
</ribbon:Button>

EDIT: Oh... you made it a string. It still works though oddly enough... just gives me the blue squiggle.


[Modified at 03/08/2010 07:20 PM]

Comments (2)

Posted 15 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
This is a bug in the VS designer and not anything we'd have control over. I believe you said you had VS 2010 beta in the past and we found this bug report:
https://connect.microsoft.com/VisualStudio/feedback/details/518623/textblock-text-does-not-support-multibinding-vs2010-beta-2?wa=wsignin1.0


Actipro Software Support

Posted 15 years ago by SledgeHammer01
Avatar
Ah... OK, thanks.
The latest build of this product (v24.1.3) was released 1 month ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.