I'm using a Ribbon control from RibbonControlLibrary for .net 3.5.
I can't use RibbonWindow
for some presentation-compatibility issues. So I place a Ribbon control inside Window
.
There are no visible issues, but I'm getting 2 error messages in my VisualStudio output window.
Those messages are:
System.Windows.Data Error: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='Microsoft.Windows.Controls.Ribbon.RibbonWindow', AncestorLevel='1''. BindingExpression:Path=WindowState; DataItem=null; target element is 'Ribbon' (Name=''); target property is 'NoTarget' (type 'Object')
System.Windows.Data Error: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='Microsoft.Windows.Controls.Ribbon.RibbonWindow', AncestorLevel='1''. BindingExpression:Path=IsActive; DataItem=null; target element is 'Ribbon' (Name=''); target property is 'NoTarget' (type 'Object')
This can be reproduced just adding a Ribbon
to a Window
and running the application.
Is there a way to tell Ribbon not to try to bind anything exactly to RibbonWindow but for Window?