This is a migrated thread and some comments may be shown as answers.

RadDatagrid IndexOutOfRange issue

1 Answer 86 Views
DataGrid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
petitponey
Top achievements
Rank 1
petitponey asked on 04 Feb 2016, 10:44 AM

Hi,

I have an IndexOutOfRange error but this occurs rarely and I can't reproduce it. Please could you investigate if a check can be added to avoid IndexOutOfRange
exception?

 Acording the stack trace, MeasureVertically seems to call UpdateAverageLength with a bad endIndex.

I use the last published version of Telerik UI for Windows 8.1 (2016.1.113.45)

Index was outside the bounds of the array.
Stack Trace:
System.IndexOutOfRangeException
   at Telerik.UI.Xaml.Controls.Grid.IndexStorage.ValueForIndex(Int32 index, Boolean approximate)
   at Telerik.Data.Core.Layouts.CompactLayout.UpdateAverageLength(Int32 startIndex, Int32 endIndex)
   at Telerik.UI.Xaml.Controls.Grid.NodePool`2.MeasureVertically(RadSize availableSize, Double offset)
   at Telerik.UI.Xaml.Controls.Grid.NodePool`2.OnMeasure(RadSize availableSize, Double offset, Int32 frozenElementsCount)
   at Telerik.UI.Xaml.Controls.Grid.Model.GridModel.MeasureCells(RadSize newAvailableSize)
   at Telerik.UI.Xaml.Controls.Grid.RadDataGrid.OnCellsPanelMeasure(RadSize newAvailableSize)
   at Telerik.UI.Xaml.Controls.Grid.Primitives.DataGridCellsPanel.MeasureOverride(Size availableSize)

1 Answer, 1 is accepted

Sort by
0
Ivaylo Gergov
Telerik team
answered on 09 Feb 2016, 11:05 AM
Hi,

Thank you for contacting us.

We will try to reproduce the issue and we will see what we can do. Meanwhile, if you manage to reproduce the exception, please send us some sample project so we can further investigate.

Regards,
Ivaylo Gergov
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
DataGrid
Asked by
petitponey
Top achievements
Rank 1
Answers by
Ivaylo Gergov
Telerik team
Share this question
or