When using the Office2016Touch theme and the default control template, the following binding errors can be observed in Visual Studio output:
System.Windows.Data Error: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='System.Windows.Controls.ContentPresenter', AncestorLevel='1''. BindingExpression:Path=(TextElement.Foreground); DataItem=null; target element is 'TextBlock' (Name=''); target property is 'Foreground' (type 'Brush')
System.Windows.Data Error: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='System.Windows.Controls.ContentPresenter', AncestorLevel='1''. BindingExpression:Path=(TextElement.Foreground); DataItem=null; target element is 'TextBlock' (Name=''); target property is 'Foreground' (type 'Brush')
System.Windows.Data Error: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='System.Windows.Controls.ContentPresenter', AncestorLevel='1''. BindingExpression:Path=(TextElement.Foreground); DataItem=null; target element is 'TextBlock' (Name=''); target property is 'Foreground' (type 'Brush')
System.Windows.Data Error: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='System.Windows.Controls.ContentPresenter', AncestorLevel='1''. BindingExpression:Path=(TextElement.Foreground); DataItem=null; target element is 'TextBlock' (Name=''); target property is 'Foreground' (type 'Brush')
Setup
For your convenience, a reproducible project is attached.
The fix will be available in the R1 2018 SP2 Release.
Found with JustDecompile : [DefaultValue(-1)] public int PageIndex { get { return (int)base.GetValue(RadDataPager.PageIndexProperty); } set { base.SetValue(RadDataPager.PageIndexProperty, value); } } When binding values to PageSize and PageIndex, the default value cause erratic exceptions... System.ArgumentOutOfRangeException: PageIndex cannot be negative when PageSize is positive. I actually never set negative value, it seems to be caused by your default value... I also get this sometimes : PageIndex can only be set to -1 when the PageSize is 0 I don't see how 0 could be a valid value in this case, and I never set it to 0, Why would I want to put -1 as PageIndex? 0 would be the right default value IMHO. How can I make it work?