Completed
Last Updated: 30 Jul 2013 02:55 by ADMIN
ADMIN
Georgi I. Georgiev
Created on: 30 Jul 2013 02:55
Category: GridView
Type: Bug Report
0
FIX. RadGridView - Selection with shift + arrows on hierarchical grid is incorrect
To reproduce: 
- generate the hierarchy using the following code:
radGridView1.SelectionMode = GridViewSelectionMode.CellSelect;
            radGridView1.MultiSelect = true;
            radGridView1.ClipboardCopyMode = GridViewClipboardCopyMode.EnableWithoutHeaderText;
            radGridView1.ClipboardPasteMode = GridViewClipboardPasteMode.Enable;
            radGridView1.AutoGenerateColumns = true;

            radGridView1.CellValueChanged += grid_CellValueChanged;
            radGridView1.EnableSorting = true;
            radGridView1.AllowMultiColumnSorting = true;
            radGridView1.ShowGroupPanel = true;
            radGridView1.EnableFiltering = true;
            radGridView1.ShowFilteringRow = false;
            radGridView1.MasterTemplate.ShowHeaderCellButtons = true; 

            DataTable dt1 = new DataTable();
            DataTable dt2 = new DataTable();
            for (int i = 0; i < 10; i++)
            {
                dt1.Columns.Add("Column" + i);
                dt2.Columns.Add("Column" + i);
            }

            var temp = new GridViewTemplate();
            temp.AutoGenerateColumns = true;
            radGridView1.Templates.Add(temp);
            var rel = new GridViewRelation(radGridView1.MasterTemplate, temp);
            rel.ChildColumnNames.Add("Column1");
            rel.ParentColumnNames.Add("Column1");
            radGridView1.Relations.Add(rel);

            radGridView1.MasterTemplate.DataSource = dt1;
            dt1.Rows.Add(1, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6, 9);
            dt1.Rows.Add(2, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6, 9);
            dt1.Rows.Add(3, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6, 9);
            dt1.Rows.Add(4, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6, 9);
            dt1.Rows.Add(5, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6, 9);

            dt2.Rows.Add(1, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6);
            dt2.Rows.Add(1, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6);
            dt2.Rows.Add(1, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6);
            dt2.Rows.Add(2, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6);
            dt2.Rows.Add(2, "sdf", "sdfsfqwert", 1, 2, 3, 4, 7, 6);
            temp.DataSource = dt2;

1. Run the project with the generated hierarchy
2. Select second cell in first row.
3. Expand first row and select fifth cell in first child row.
4. Hold Shift-Key and press down arrow after that right arrow twice.
selection will be incorrect
0 comments