or
<telerikGrid:GridViewDataColumn Header="Notes" Name="colNoteText" IsReadOnly="True" IsFilterable="False" IsGroupable="False" IsSortable="False"> <telerikGrid:GridViewDataColumn.CellTemplate> <DataTemplate> <Grid> <telerikDocumentsRtf:RtfDataProvider Name="rtfDataProvider" Rtf="{Binding Path=Note, Mode=TwoWay}" RichTextBox="{Binding ElementName=TextBoxNote}" /> <telerik:RadRichTextBox Name="TextBoxNote" > </telerik:RadRichTextBox> </Grid> </DataTemplate> </telerikGrid:GridViewDataColumn.CellTemplate> </telerikGrid:GridViewDataColumn>Error: 0 : System.NullReferenceException: Object reference not set to an instance of an object at Telerik.Windows.Controls.GridView.GridViewItemContainerGenerator.Remove(GeneratorPosition position, Int32 count, Boolean isRecycling) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\GridViewItemContainerGenerator.cs:Line 288. at Telerik.Windows.Controls.GridView.GridViewItemContainerGenerator.System.Windows.Controls.Primitives.IRecyclingItemContainerGenerator.Recycle(GeneratorPosition position, Int32 count) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\GridViewItemContainerGenerator.cs:Line 626. at Telerik.Windows.Controls.GridView.GridViewVirtualizingPanel.CleanupRange(IList children, IItemContainerGenerator generator, Int32 startIndex, Int32 count) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\Virtualization\GridViewVirtualizingPanel.cs:Line 2637. at Telerik.Windows.Controls.GridView.GridViewVirtualizingPanel.CleanupContainers(Int32 firstViewport, BaseItemsControl itemsControl) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\Virtualization\GridViewVirtualizingPanel.cs:Line 2366. at Telerik.Windows.Controls.GridView.GridViewVirtualizingPanel.MeasureOverride(Size constraint) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\Virtualization\GridViewVirtualizingPanel.cs:Line 1193. at System.Windows.FrameworkElement.MeasureCore(Size availableSize) at System.Windows.UIElement.Measure(Size availableSize) at System.Windows.ContextLayoutManager.UpdateLayout() at System.Windows.UIElement.UpdateLayout() at Telerik.Windows.Documents.UI.DocumentWebLayoutPresenter.UpdateEditorLayout() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Documents\UI\DocumentWebLayoutPresenter.cs:Line 716. at Telerik.Windows.Documents.UI.DocumentWebLayoutPresenter.DoOnDocumentChanged() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Documents\UI\DocumentWebLayoutPresenter.cs:Line 448. at Telerik.Windows.Documents.UI.DocumentPresenterBase.OnOwnerChanged() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Documents\UI\DocumentPresenterBase.cs:Line 1025. at Telerik.Windows.Documents.UI.DocumentPresenterBase.set_Owner(RadRichTextBox value) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Documents\UI\DocumentPresenterBase.cs:Line 117. at Telerik.Windows.Controls.RadRichTextBox.InitActiveEditorPresenter() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Documents\UI\RadRichTextBox.cs:Line 2632. at Telerik.Windows.Controls.RadRichTextBox.set_Document(RadDocument value) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Documents\UI\RadRichTextBox.cs:Line 818. at Telerik.Windows.Documents.FormatProviders.DataProviderBase.UpdateDocument() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Documents\FormatProviders\DataProviderBase.cs:Line 190. at Telerik.Windows.Documents.FormatProviders.DataProviderBase.StringPropertyChangedCallback(DependencyObject sender, DependencyPropertyChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Documents\FormatProviders\DataProviderBase.cs:Line 120. at System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e) at System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e) at System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) at System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType) at System.Windows.DependencyObject.InvalidateProperty(DependencyProperty dp) at System.Windows.Data.BindingExpressionBase.Invalidate(Boolean isASubPropertyChange) at System.Windows.Data.BindingExpression.TransferValue(Object newValue, Boolean isASubPropertyChange) at System.Windows.Data.BindingExpression.Activate(Object item) at System.Windows.Data.BindingExpression.OnDataContextChanged(DependencyObject contextElement) at System.Windows.Data.BindingExpression.HandlePropertyInvalidation(DependencyObject d, DependencyPropertyChangedEventArgs args) at System.Windows.Data.BindingExpressionBase.OnPropertyInvalidation(DependencyObject d, DependencyPropertyChangedEventArgs args) at System.Windows.Data.BindingExpression.OnPropertyInvalidation(DependencyObject d, DependencyPropertyChangedEventArgs args) at System.Windows.DependentList.InvalidateDependents(DependencyObject source, DependencyPropertyChangedEventArgs sourceArgs) at System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) at System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType) at System.Windows.TreeWalkHelper.OnInheritablePropertyChanged(DependencyObject d, InheritablePropertyChangeInfo info) at System.Windows.DescendentsWalker`1._VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.VisitNode(FrameworkElement fe) at System.Windows.DescendentsWalker`1.VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.WalkLogicalChildren(FrameworkElement feParent, FrameworkContentElement fceParent, IEnumerator logicalChildren) at System.Windows.DescendentsWalker`1.WalkFrameworkElementLogicalThenVisualChildren(FrameworkElement feParent, Boolean hasLogicalChildren) at System.Windows.DescendentsWalker`1.IterateChildren(DependencyObject d) at System.Windows.DescendentsWalker`1._VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.VisitNode(FrameworkElement fe) at System.Windows.DescendentsWalker`1.VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.WalkLogicalChildren(FrameworkElement feParent, FrameworkContentElement fceParent, IEnumerator logicalChildren) at System.Windows.DescendentsWalker`1.WalkFrameworkElementLogicalThenVisualChildren(FrameworkElement feParent, Boolean hasLogicalChildren) at System.Windows.DescendentsWalker`1.IterateChildren(DependencyObject d) at System.Windows.DescendentsWalker`1._VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.VisitNode(FrameworkElement fe) at System.Windows.DescendentsWalker`1.VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.WalkLogicalChildren(FrameworkElement feParent, FrameworkContentElement fceParent, IEnumerator logicalChildren) at System.Windows.DescendentsWalker`1.WalkFrameworkElementLogicalThenVisualChildren(FrameworkElement feParent, Boolean hasLogicalChildren) at System.Windows.DescendentsWalker`1.IterateChildren(DependencyObject d) at System.Windows.DescendentsWalker`1._VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.VisitNode(FrameworkElement fe) at System.Windows.DescendentsWalker`1.VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.WalkFrameworkElementLogicalThenVisualChildren(FrameworkElement feParent, Boolean hasLogicalChildren) at System.Windows.DescendentsWalker`1.IterateChildren(DependencyObject d) at System.Windows.DescendentsWalker`1._VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.VisitNode(FrameworkElement fe) at System.Windows.DescendentsWalker`1.VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.WalkLogicalChildren(FrameworkElement feParent, FrameworkContentElement fceParent, IEnumerator logicalChildren) at System.Windows.DescendentsWalker`1.WalkFrameworkElementLogicalThenVisualChildren(FrameworkElement feParent, Boolean hasLogicalChildren) at System.Windows.DescendentsWalker`1.IterateChildren(DependencyObject d) at System.Windows.DescendentsWalker`1._VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.VisitNode(FrameworkElement fe) at System.Windows.DescendentsWalker`1.VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.WalkFrameworkElementLogicalThenVisualChildren(FrameworkElement feParent, Boolean hasLogicalChildren) at System.Windows.DescendentsWalker`1.IterateChildren(DependencyObject d) at System.Windows.DescendentsWalker`1._VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.VisitNode(FrameworkElement fe) at System.Windows.DescendentsWalker`1.VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.WalkLogicalChildren(FrameworkElement feParent, FrameworkContentElement fceParent, IEnumerator logicalChildren) at System.Windows.DescendentsWalker`1.WalkFrameworkElementLogicalThenVisualChildren(FrameworkElement feParent, Boolean hasLogicalChildren) at System.Windows.DescendentsWalker`1.IterateChildren(DependencyObject d) at System.Windows.DescendentsWalker`1._VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.VisitNode(FrameworkElement fe) at System.Windows.DescendentsWalker`1.VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.WalkLogicalChildren(FrameworkElement feParent, FrameworkContentElement fceParent, IEnumerator logicalChildren) at System.Windows.DescendentsWalker`1.WalkFrameworkElementLogicalThenVisualChildren(FrameworkElement feParent, Boolean hasLogicalChildren) at System.Windows.DescendentsWalker`1.IterateChildren(DependencyObject d) at System.Windows.DescendentsWalker`1._VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.VisitNode(FrameworkElement fe) at System.Windows.DescendentsWalker`1.VisitNode(DependencyObject d) at System.Windows.DescendentsWalker`1.WalkFrameworkElementLogicalThenVisualChildren(FrameworkElement feParent, Boolean hasLogicalChildren) at System.Windows.DescendentsWalker`1.IterateChildren(DependencyObject d) at System.Windows.DescendentsWalker`1.StartWalk(DependencyObject startNode, Boolean skipStartNode) at System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e) at System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) at System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType) at System.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Object value, PropertyMetadata metadata, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType, Boolean isInternal) at System.Windows.DependencyObject.SetValue(DependencyProperty dp, Object value) at System.Windows.FrameworkElement.set_DataContext(Object value) at Telerik.Windows.Controls.GridView.DataCellsPresenter.OnItemChanged(Object oldItem, Object newItem) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\DataCellsPresenter.cs:Line 313. at Telerik.Windows.Controls.GridView.DataCellsPresenter.set_Item(Object value) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\DataCellsPresenter.cs:Line 301. at Telerik.Windows.Controls.GridView.GridViewRowItem.OnItemChanged(Object oldItem, Object newItem) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\Rows\GridViewRowItem.cs:Line 581. at Telerik.Windows.Controls.GridView.GridViewRow.OnItemChanged(Object oldItem, Object newItem) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\Rows\GridViewRow.cs:Line 529. at Telerik.Windows.Controls.RadRowItem.OnItemChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\RadRowItem.cs:Line 47. at System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e) at System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e) at System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) at System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType) at System.Windows.DependencyObject.ClearValueCommon(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata) at System.Windows.DependencyObject.ClearValue(DependencyProperty dp) at Telerik.Windows.Controls.GridView.GridViewRowItem.ClearRow(GridViewDataControl owningDataGrid) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\Rows\GridViewRowItem.cs:Line 702. at Telerik.Windows.Controls.GridView.GridViewRow.ClearRow(GridViewDataControl owningDataGrid) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\Rows\GridViewRow.cs:Line 1798. at Telerik.Windows.Controls.GridView.GridViewDataControl.ClearContainerForItemOverride(DependencyObject element, Object item) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\GridViewDataControl.cs:Line 7734. at Telerik.Windows.Controls.GridView.BaseItemsControl.Telerik.Windows.Controls.GridView.IGeneratorHost.ClearContainerForItem(DependencyObject container, Object item) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\BaseItemsControl.cs:Line 264. at Telerik.Windows.Controls.GridView.GridViewItemContainerGenerator.UnlinkContainerFromItem(DependencyObject container, Object item, Boolean isRecycled) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\GridViewItemContainerGenerator.cs:Line 2265. at Telerik.Windows.Controls.GridView.GridViewItemContainerGenerator.UnlinkContainerFromItem(DependencyObject container, Object item) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\GridViewItemContainerGenerator.cs:Line 2205. at Telerik.Windows.Controls.GridView.GridViewItemContainerGenerator.RecycleRealizedContainer(DependencyObject container, Object item) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\GridViewItemContainerGenerator.cs:Line 606. at Telerik.Windows.Controls.GridView.GridViewItemContainerGenerator.RecycleAllRealizedContainersInBlock(RealizedItemBlock rib) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\GridViewItemContainerGenerator.cs:Line 600. at Telerik.Windows.Controls.GridView.GridViewItemContainerGenerator.RecycleAllRealizedContainers() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\GridViewItemContainerGenerator.cs:Line 583. at Telerik.Windows.Controls.GridView.GridViewItemContainerGenerator.ReInitializeContainers() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\GridViewItemContainerGenerator.cs:Line 488. at Telerik.Windows.Controls.GridView.GridViewDataControl.ReuseContainersOnReset() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\GridViewDataControl.cs:Line 8364. at Telerik.Windows.Controls.GridView.GridViewDataControl.OnItemsChanged(NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\GridViewDataControl.cs:Line 8338. at Telerik.Windows.Controls.GridView.BaseItemsControl.OnItemCollectionChanged(Object sender, NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\ItemsControl\BaseItemsControl.cs:Line 691. at System.Collections.Specialized.NotifyCollectionChangedEventHandler.Invoke(Object sender, NotifyCollectionChangedEventArgs e) at Telerik.Windows.Data.DataItemCollection.OnCollectionChanged(NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\DataItemCollection.cs:Line 665. at Telerik.Windows.Data.DataItemCollection.OnCollectionViewCollectionChanged(NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\DataItemCollection.cs:Line 642. at Telerik.Windows.Data.DataItemCollection.Telerik.Windows.Data.IWeakEventListener<System.Collections.Specialized.NotifyCollectionChangedEventArgs>.ReceiveWeakEvent(Object sender, NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\DataItemCollection.cs:Line 1046. at Telerik.Windows.Data.WeakEvent.WeakListener`1.Handler(Object sender, TArgs args) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\WeakEvents\WeakEvent.cs:Line 33. at Telerik.Windows.Data.QueryableCollectionView.OnCollectionChanged(NotifyCollectionChangedEventArgs args) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\QueryableCollectionView.cs:Line 679. at Telerik.Windows.Data.QueryableCollectionView.RefreshOverride() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\QueryableCollectionView.cs:Line 824. at Telerik.Windows.Data.QueryableCollectionView.RefreshInternal() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\QueryableCollectionView.cs:Line 771. at Telerik.Windows.Data.QueryableCollectionView.RefreshOrDefer() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\QueryableCollectionView.cs:Line 765. at Telerik.Windows.Data.QueryableCollectionView.InvalidatePagingAndRefresh() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\QueryableCollectionView.cs:Line 392. at Telerik.Windows.Data.QueryableCollectionView.OnSortDescriptorsCollectionChanged(Object sender, NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\QueryableCollectionView.cs:Line 403. at System.Collections.Specialized.NotifyCollectionChangedEventHandler.Invoke(Object sender, NotifyCollectionChangedEventArgs e) at System.Collections.ObjectModel.ObservableCollection`1.OnCollectionChanged(NotifyCollectionChangedEventArgs e) at Telerik.Windows.Data.RadObservableCollection`1.OnCollectionChanged(NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\RadObservableCollection.cs:Line 143. at Telerik.Windows.Data.ObservableItemCollection`1.OnCollectionChanged(NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\ObservableItemCollection.cs:Line 91. at Telerik.Windows.Data.RadObservableCollection`1.ResumeNotifications() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\RadObservableCollection.cs:Line 259. at Telerik.Windows.Data.CollectionHelper.Reset(IEnumerable source, IList target, Func`2 itemConverter) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\CollectionHelper.cs:Line 450. at Telerik.Windows.Data.CollectionHelper.Reset(IEnumerable source, IList target) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\CollectionHelper.cs:Line 420. at Telerik.Windows.Data.ObservableCollectionManager.HandleCollectionChanged(IList sender, NotifyCollectionChangedEventArgs args) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\Synchronization\ObservableCollectionManager.cs:Line 119. at Telerik.Windows.Data.ObservableCollectionManager.Telerik.Windows.Data.IWeakEventListener<System.Collections.Specialized.NotifyCollectionChangedEventArgs>.ReceiveWeakEvent(Object sender, NotifyCollectionChangedEventArgs args) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\Synchronization\ObservableCollectionManager.cs:Line 86. at Telerik.Windows.Data.WeakEvent.WeakListener`1.Handler(Object sender, TArgs args) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\WeakEvents\WeakEvent.cs:Line 33. at System.Collections.Specialized.NotifyCollectionChangedEventHandler.Invoke(Object sender, NotifyCollectionChangedEventArgs e) at System.Collections.ObjectModel.ObservableCollection`1.OnCollectionChanged(NotifyCollectionChangedEventArgs e) at Telerik.Windows.Data.RadObservableCollection`1.OnCollectionChanged(NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\RadObservableCollection.cs:Line 143. at Telerik.Windows.Data.ObservableItemCollection`1.OnCollectionChanged(NotifyCollectionChangedEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\ObservableItemCollection.cs:Line 91. at Telerik.Windows.Data.RadObservableCollection`1.ResumeNotifications() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Data\Collections\RadObservableCollection.cs:Line 259. at Telerik.Windows.Controls.GridView.GridViewDataControl.PerformSorting(GridViewSortingEventArgs sortingArgs) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\GridViewDataControl.Sorting.cs:Line 139. at Telerik.Windows.Controls.GridView.GridViewDataControl.<>c__DisplayClass74.<Sort>b__73() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\GridViewDataControl.Sorting.cs:Line 89. at Telerik.Windows.Controls.CursorManager.PerformTimeConsumingOperation(FrameworkElement frameworkElement, Action action) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Controls\CursorManager.cs:Line 16. at Telerik.Windows.Controls.GridView.GridViewDataControl.Sort(GridViewColumn column, Boolean appendToExisting) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\GridViewDataControl.Sorting.cs:Line 79. at Telerik.Windows.Controls.GridView.GridViewHeaderCell.RequestSort(Boolean appendToExisting) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\Cells\GridViewHeaderCell.cs:Line 374. at Telerik.Windows.Controls.GridView.GridViewHeaderCell.OnMouseLeftButtonUp(MouseButtonEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\GridView\GridView\GridView\Cells\GridViewHeaderCell.cs:Line 363. at System.Windows.UIElement.OnMouseLeftButtonUpThunk(Object sender, MouseButtonEventArgs e) at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget) at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target) at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs) at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised) at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent) at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e) at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget) at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target) at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs) at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised) at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args) at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args) at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted) at System.Windows.Input.InputManager.ProcessStagingArea() at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input) at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport) at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel) at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled) at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled) at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled) at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o) at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs) at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler) at System.Windows.Threading.Dispatcher.InvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs) at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam) at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg) at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame) at System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame) at System.Windows.Threading.Dispatcher.Run() at System.Windows.Application.RunDispatcher(Object ignore) at System.Windows.Application.RunInternal(Window window) at System.Windows.Application.Run(Window window) at System.Windows.Application.Run()Dear Support,
I want to Binding to GridView.SelectedItems.Count or other DependencyProperty, but it returns nothing, no error no exception. Please help me how to Binding in telerik:GridViewColumn.Footer.
Other test results:
Code is below:
<telerik:GridViewDataColumn Header="PO Number" DataMemberBinding="{Binding PONUMBER}"> <telerik:GridViewDataColumn.AggregateFunctions> <custom:CountDistinctFunction Caption="Distinct PO Count:" /> </telerik:GridViewDataColumn.AggregateFunctions> <telerik:GridViewDataColumn.Footer> <StackPanel Orientation="Vertical" Margin="0"> <StackPanel Orientation="Horizontal"> <TextBlock Text="Selected:" /> <TextBlock Text="{Binding ElementName=myGridView, Path=SelectedItems.Count}" /> </StackPanel> <telerik:AggregateResultsList ItemsSource="{Binding}" VerticalAlignment="Center"> <ItemsControl.ItemTemplate> <DataTemplate> <StackPanel Orientation="Horizontal" VerticalAlignment="Center"> <TextBlock VerticalAlignment="Center" Text="{Binding Caption}" /> <TextBlock VerticalAlignment="Center" Text="{Binding FormattedValue}" /> </StackPanel> </DataTemplate> </ItemsControl.ItemTemplate> </telerik:AggregateResultsList> </StackPanel> </telerik:GridViewDataColumn.Footer> </telerik:GridViewDataColumn>using System.Linq;using System.Windows;using NAPAData;using System.Collections.ObjectModel;namespace wpfNAPADashBoard.Pages{ /// <summary> /// Interaction logic for AcctInfo.xaml /// </summary> public partial class AcctInfo : Window { //Make a connection to the database Entity class context. TAMSdbDataContext db = new TAMSdbDataContext(); //Access the user name saved to the iDictionary as part of the login process. string uName = (string)App.Current.Properties["UserName"]; //Create an observable collection to bind the raddataform to. The collection is empty at this point. ObservableCollection<UserDetail> obCol = new ObservableCollection<UserDetail>(); public AcctInfo() { InitializeComponent(); } private void Window_Loaded(object sender, RoutedEventArgs e) { //upon loading the window - LINQ query to populate the observable collection with a single record from the database var userDetails = from ud in db.UserDetails where ud.UserName == uName select ud; foreach (var i in userDetails) { obCol.Add(i); } //Binds the observable collection to the dataform AccountInfo.ItemsSource = obCol.ToList(); } private void RadMenuItem_Click(object sender, Telerik.Windows.RadRoutedEventArgs e) { //Used by the RadMenu to close the window popup this.Close(); } private void AccountInfo_EditEnded(object sender, Telerik.Windows.Controls.Data.DataForm.EditEndedEventArgs e) { //AccountInfo_EditEnded is used to save changes made to the observable collection to the database record using LINQ. //First perform a LINQ query against the observable collection. var result = (from o in obCol select o); //Now loop through the "result" query. foreach (var x in result) { //LINQ query to pull the matching observable collection record from the database. var userDetails = from ud in db.UserDetails where ud.UserName == uName select ud; //Apply the observable collection values to the LINQ query values. foreach (var i in userDetails) { i.FirstName = x.FirstName; i.LastName = x.LastName; i.CompanyName = x.CompanyName; i.Address1 = x.Address1; i.Address2 = x.Address2; i.Address3 = x.Address3; i.City = x.City; i.Region = x.Region; i.Country = x.Country; i.Phone = x.Phone; i.WebSite = x.WebSite; i.Email = x.Email; //Save changes to the database db.SubmitChanges(); } } } }}<Window x:Class="wpfNAPADashBoard.Pages.AcctInfo" xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" Title="Account Information" WindowStartupLocation="CenterScreen" Height="419" Width="806" Loaded="Window_Loaded"> <Grid> <Grid.Resources> <DataTemplate x:Key="MyTemplate"> <Grid> <Grid.ColumnDefinitions> <ColumnDefinition/> <ColumnDefinition/> </Grid.ColumnDefinitions> <Grid.RowDefinitions> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> <RowDefinition/> </Grid.RowDefinitions> <telerik:DataFormDataField Grid.Row="0" Grid.Column="0" Label="Client ID:" DataMemberBinding="{Binding ClientID, Mode=OneWay}" IsEnabled="False" /> <telerik:DataFormDataField Grid.Row="1" Grid.Column="0" Label="Company Name:" DataMemberBinding="{Binding CompanyName, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="2" Grid.Column="0" Label="Address 1:" DataMemberBinding="{Binding Address1, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="3" Grid.Column="0" Label="Address 2:" DataMemberBinding="{Binding Address2, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="4" Grid.Column="0" Label="Address 3:" DataMemberBinding="{Binding Address3, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="5" Grid.Column="0" Label="City:" DataMemberBinding="{Binding City, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="6" Grid.Column="0" Label="State/Region:" DataMemberBinding="{Binding Region, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="7" Grid.Column="0" Label="PostalCode:" DataMemberBinding="{Binding PostalCode, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="8" Grid.Column="0" Label="Country:" DataMemberBinding="{Binding Country, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="0" Grid.Column="1" Label="Company ID:" DataMemberBinding="{Binding CompanyID, Mode=OneWay}" IsEnabled="False" /> <telerik:DataFormDataField Grid.Row="1" Grid.Column="1" Label="First Name:" DataMemberBinding="{Binding FirstName, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="2" Grid.Column="1" Label="Last Name:" DataMemberBinding="{Binding LastName, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="3" Grid.Column="1" Label="Email:" DataMemberBinding="{Binding Email, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="4" Grid.Column="1" Label="Phone:" DataMemberBinding="{Binding Phone, Mode=TwoWay}" /> <telerik:DataFormDataField Grid.Row="5" Grid.Column="1" Label="Website:" DataMemberBinding="{Binding WebSite, Mode=TwoWay}" /> </Grid> </DataTemplate> </Grid.Resources> <Grid.RowDefinitions> <RowDefinition Height="auto" /> <RowDefinition Height="*" /> </Grid.RowDefinitions> <telerik:RadMenu Name="radMenu1" VerticalAlignment="Top" ClickToOpen="True" telerik:StyleManager.Theme="Office_Black" Grid.Row="0"> <telerik:RadMenuItem Header="Close" Click="RadMenuItem_Click" /> </telerik:RadMenu> <telerik:RadDataForm x:Name="AccountInfo" AutoGenerateFields="False" ReadOnlyTemplate="{StaticResource MyTemplate}" EditTemplate="{StaticResource MyTemplate}" Grid.Row="1" telerik:StyleManager.Theme="Office_Black" CommandButtonsVisibility="Cancel,Commit,Edit" EditEnded="AccountInfo_EditEnded" > </telerik:RadDataForm> </Grid></Window>