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

[Solved] Infinite loop bug in GridViews that contain a toggle column

1 Answer 125 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Matt Greer
Top achievements
Rank 1
Matt Greer asked on 22 Nov 2010, 04:54 PM

I have found a bug in the RadGridView. See bottom of post for source code that demonstrates it.

If a RadGridView contains a GridViewToggleRowDetailsColumn, then a certain use case leads to an infinite loop.

Reproduction:
1) In the grid in the sample project, double click the Name cell to edit the name in the grid.
2) Click on the right side of the name to unselect the text in the editing TextBox that appears
3) Use CTRL+Left Arrow to move the cursor word by word towards the beginning of the name.
4) Once arrived at the beginning of the name, use CTRL+Left Arrow again

Expected result: nothing as the cursor is at the beginning of the textbox
Actual result: infinite loop occurs.

This happens in both debug and release, with or without a debugger attached. When a debugger is attached and I pause it, it always is paused at:

System.dll!System.Net.SafeCloseSocket.InnerSafeCloseSocket.Accept(System.Net.SafeCloseSocket socketHandle, byte[] socketAddress, ref int socketAddressSize)

 

My setup is:
Windows 7 64 bit
IE 8 version 8.0.7600.16385
also occurs in Chrome: 7.0.517.44
Silverlight version: 4.0.50917.0
.NET 4
Telerik version: 2010.2.812.1040




Here is a simple sample that reproduces it:

MainPage.xaml

<UserControl x:Class="RadGridViewTest.MainPage"
    mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="480" xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation">
  <Grid x:Name="LayoutRoot">
        <telerik:RadGridView x:Name="_grid">
            <telerik:RadGridView.Columns>
                <telerik:GridViewToggleRowDetailsColumn />
            </telerik:RadGridView.Columns>
        </telerik:RadGridView>
    </Grid>
</UserControl>


MainPage.xaml.cs
using System.Collections.Generic;
using System.Windows.Controls;
   
namespace RadGridViewTest
{
    public class MyData
    {
        public string Name { get; set; }
        public int Age { get; set; }
    }
   
    public partial class MainPage : UserControl
    {
        public MainPage()
        {
            InitializeComponent();
   
            List<MyData> data = new List<MyData>
            {
                new MyData() { Name = "Henry Wordsworth Longfellow the Fourth", Age = 25 }
            };
   
   
            _grid.ItemsSource = data;
        }
    }
}

1 Answer, 1 is accepted

Sort by
0
Ivan Ivanov
Telerik team
answered on 23 Nov 2010, 12:23 PM
Hi Matt Greer,

We have managed to reproduce this behavior and we have logged it in our PITS system.

Here you can find the PITS Issue: Public URL

Thank you for your help and accept our apologies.

Sincerely,
Ivan X1
the Telerik team
Browse the videos here>> to help you get started with RadControls for Silverlight
Tags
GridView
Asked by
Matt Greer
Top achievements
Rank 1
Answers by
Ivan Ivanov
Telerik team
Share this question
or