BindingExpression in VS2013 theme
cuellius opened this issue · 3 comments
If I use VS2013 theme, I get these errors in Visual Studio's Output Window:
System.Windows.Data Error: 40 : BindingExpression path error: 'RootDocument' property not found on 'object' ''LayoutDocumentFloatingWindow' (HashCode=36044558)'. BindingExpression:Path=Model.RootDocument.IsActive; DataItem='LayoutDocumentFloatingWindowControl' (Name=''); target element is 'LayoutDocumentFloatingWindowControl' (Name=''); target property is 'NoTarget' (type 'Object')
Please, fix this issue.
P. S. Version 4.0.0 from NuGet
I found a solution (maybe it is only partial solution): Add to class LayoutDocumentFloatingWindow
property RootDocument
as:
public LayoutContent RootDocument => RootPanel?.Descendents(). OfType<LayoutDocumentPane().FirstOrDefault(p => p.IsVisible)?.SelectedContent;
Thanks for the feedback and suggestions but inventing a property just to make an error message go away is not a good fix. The right fix in this case to adjust the binding to the correct binding path which has slightly changed in comparison to the previously released version.