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

Excel Like Filtering Crashes App When duplicate decimals exist

4 Answers 110 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Joe Sugden
Top achievements
Rank 1
Joe Sugden asked on 10 Dec 2010, 08:49 PM

Hello,

We noticed the following problem with the RadGridView:

When you have Excel like filtering enabled, and you click on the filtering icon for a column that has duplicate decimal numbers, the app crashes with a message like this:

"Item has already been added. Key in dictionary: '26.7'  Key being added: '26.7'"

Please find attached screenshots with grid of data and error message.

Configuration used:

Rad Controls for Win Forms 2010 Q3; WinXP, .NET 2.0, VB.NET

Here is the code that populates a test grid with data:

Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
    Dim rand As Random = New Random()
    Dim dt As DataTable = New DataTable()
 
    dt.Columns.Add("Pecentage", GetType(Double))
    dt.Columns.Add("Price", GetType(Double))
 
    For i As Integer = 1 To 10000
        dt.Rows.Add(rand.Next(0, 100) + rand.Next(0, 100) * 0.1, rand.Next(0, 1000000))
    Next
 
    grdData.DataSource = dt
    grdData.BestFitColumns()
End Sub

Thanks.

4 Answers, 1 is accepted

Sort by
0
Accepted
Richard Slade
Top achievements
Rank 2
answered on 10 Dec 2010, 08:59 PM
Hi Joe,

I reported this issue (actually, with duplicate null values in a GridViewTextBoxColumn, but the same thing - see trace below) to Telerik soon after the Q3 release came out. I had a note back saying it was going to be fixed in the up coming service pack.

The error I received was..
System.ArgumentException was unhandled
  Message="Item has already been added. Key in dictionary: ''  Key being added: ''"
  Source="mscorlib"

Hope this helps
Richard
0
Joe Sugden
Top achievements
Rank 1
answered on 10 Dec 2010, 09:07 PM
I see, thanks for the info!
0
Joe Sugden
Top achievements
Rank 1
answered on 11 Dec 2010, 12:02 AM
Does anybody know when the Service Pack is gonna be out? Don't know about the other controls but the GridView and the CommandBar seem pretty buggy..
0
Accepted
Richard Slade
Top achievements
Rank 2
answered on 11 Dec 2010, 12:13 AM
Hi

Last I heard it was due for mid-December, so it should be out next week.
All the best
Richard
Tags
GridView
Asked by
Joe Sugden
Top achievements
Rank 1
Answers by
Richard Slade
Top achievements
Rank 2
Joe Sugden
Top achievements
Rank 1
Share this question
or