Completed
Last Updated: 19 Jan 2012 09:16 by ADMIN
FIX. RadGridView - add property to GridSpinEditorElement which will prevent the value changing with mouse wheel
Completed
Last Updated: 06 Jul 2012 06:36 by ADMIN
To reproduce
- bind the grid to a binding list
- pin one of the rows
- delete this row from the binding list
- click somewhere on the grid => exception is thrown
Completed
Last Updated: 10 Jul 2012 02:47 by ADMIN
To reproduce:
rgvTest.BeginUpdate()
For ixTest As Integer = 1 To 2000
Dim rgvrTest As GridViewRowInfo = rgvTest.Rows.AddNew
rgvrTest.Cells(0).Value = "Value " & ixTest.ToString
Next
rgvTest.EndUpdate()
rgvTest.Rows(0).IsCurrent = True
MessageBox.Show(rgvTest.CurrentCell.RowIndex.ToString)
Completed
Last Updated: 14 Aug 2012 07:26 by ADMIN
To reproduce, add a grid with GridViewHyperlinkColumn and enough rows for vertical scrolling. Click a link in a cell so its link will change to visited (its color changes). Scroll down and you will see how the same visited state is transferred to other cells.
Completed
Last Updated: 09 Jan 2013 03:47 by ADMIN
To reproduce:
- Add a grid to a form and open the property builder
- Add couple columns and group by some of the columns
- Press ok -> the grid is grouped
- Open the Property Builder again, click the X button of the group to remove it and click the OK button of the Property Builder -> the group is not removed.
Completed
Last Updated: 20 Jun 2013 05:03 by ADMIN
Workaround, use the following behavior:

 public class CustomDataRowBehavior : GridDataRowBehavior
    {
        protected override bool OnMouseDownRight(MouseEventArgs e)
        {
            if (this.IsInEditMode && !this.GridViewElement.EndEdit())
    
Completed
Last Updated: 13 Nov 2015 15:17 by ADMIN
To reproduce:  Dim dockmem As New MemoryStream
    Dim gridmem As New MemoryStream

    Public Sub SetData()

        ' dgvSelectList.DataSource = Nothing
        Dim dt As DataTable
        dt = New DataTable

        dt.Columns.Add("VENDCODE")
        dt.Columns.Add("VENDNAME")
        dt.Rows.Add("AA2", "Arthur")
        dt.Rows.Add("AA2", "Arthur")

        dgvSelectList.DataSource = dt
        dgvSelectList.BestFitColumns()
    End Sub

    Private Sub frmSelectListNG2_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
        SetData()
        dgvSelectList.EnableFiltering = False
        'Save Grid and Dock layout settings to mem stream and simulate my process
        SaveSettings()
    End Sub

    Public Sub btnGO_Click(sender As System.Object, e As System.EventArgs) Handles btnGO.Click
        LoadSettings()
        dgvSelectList.SplitMode = RadGridViewSplitMode.Horizontal
        SetData()
        LoadSettings()
    End Sub

    Private Sub LoadSettings()
        gridmem.Position = 0
        dockmem.Position = 0
        dgvSelectList.LoadLayout(gridmem)
        rdkSelect.LoadFromXml(dockmem)
    End Sub

    Private Sub SaveSettings()
        gridmem.Position = 0
        dockmem.Position = 0
        dgvSelectList.SaveLayout(gridmem)
        rdkSelect.SaveToXml(dockmem)
    End Sub

Workaround - set the datasource to Nothing prior rebinding
Completed
Last Updated: 17 Nov 2015 16:27 by ADMIN
To reproduce:
- add a grid to the form and use the following code for its setup:
            radGridView2.Columns.Add("ID");
            radGridView2.Columns.Add("Title");
            radGridView2.MultiSelect = true;
            radGridView2.Columns[0].SortOrder = RadSortOrder.Ascending;
            radGridView2.ReadOnly = true;

            radGridView2.BeginUpdate();
            for (int i = 0; i < 5; i++)
            {
                GridViewDataRowInfo row = new GridViewDataRowInfo(radGridView2.MasterTemplate.MasterViewInfo);
                row.Cells["ID"].Value = i;
                row.Cells["Title"].Value = "Title " + i;
                radGridView2.Rows.Add(row);
            }
            radGridView2.EndUpdate(true);

            radGridView2.Rows[0].IsCurrent = true;
            radGridView2.Rows[0].IsSelected= true;

- Once the application is started, hold down the shift key and click the third row in the grid 

Expected result: the first three rows are selected
Actual result: the last three rows are selected

WORKAROUND:
Use the BeginUpdate and EndUpdate methods of the TableElement, not the control:
radGridView2.TableElement.BeginUpdate();
//add rows
radGridView2.TableElement.EndUpdate(true);
Completed
Last Updated: 17 Nov 2015 16:27 by ADMIN
To reproduce: bind the grid to self reference data source, and on a button click, Fill the TableAdapter

Workaround: clear the relations to clear the cache and add them back after the adapter is filled:
RadGridView1.Relations.Clear()
        Me.Table1TableAdapter.Fill(Me.Database8DataSet.Table1)
        Me.RadGridView1.Relations.AddSelfReference(Me.RadGridView1.MasterTemplate, "TaskID", "ParentTask")
Completed
Last Updated: 25 Mar 2013 06:22 by ADMIN
To reproduce:
- Set BeginEditMod to BeginEditProgrammatically
- Check/uncheck a check box cell and you will be able to edit the rest of the cells
Completed
Last Updated: 08 Oct 2014 07:15 by ADMIN
To reproduce:
Private Sub Form1_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
        BindGrid()
    End Sub

    Private Sub BindGrid()
        Dim r As New Random()
        Dim table As New DataTable()
        table.Columns.Add("ID", GetType(Integer))
        table.Columns.Add("Name", GetType(String))
        table.Columns.Add("Bool", GetType(Boolean))

        For i As Integer = 0 To 39
            table.Rows.Add(i, "Row " & i, If(r.[Next](10) > 5, True, False))
        Next

        Me.RadGridView1.DataSource = table
    End Sub

    Dim saveName As Integer

    Private Sub RadGridView1_CellEndEdit(sender As Object, e As Telerik.WinControls.UI.GridViewCellEventArgs) Handles RadGridView1.CellEndEdit
        If e.Column.Name = "Name" Then
            saveName = RadGridView1.CurrentRow.Cells("ID").Value
            BindGrid()
        End If
    End Sub

    Private Sub RadGridView1_DataBindingComplete(sender As Object, e As Telerik.WinControls.UI.GridViewBindingCompleteEventArgs) Handles RadGridView1.DataBindingComplete
        For Each row As GridViewRowInfo In RadGridView1.Rows
            If row.Cells("ID").Value = saveName Then
                row.IsCurrent = True
                RadGridView1.TableElement.EnsureRowVisible(row)
                Exit For
            End If
        Next
    End Sub
WORKAROUND:
Rebind the grid in the CellValueChanged event instead of the CellEndEdit event:

    Private Sub RadGridView1_CellValueChanged(sender As Object, e As Telerik.WinControls.UI.GridViewCellEventArgs) Handles RadGridView1.CellValueChanged
        If e.Column.Name = "Name" Then
            saveName = RadGridView1.CurrentRow.Cells("ID").Value
            BindGrid()
        End If
    End Sub
Completed
Last Updated: 20 Feb 2014 15:16 by ADMIN
To reproduce:
- Add a checkbox column to a grid
- Add the following code to the ValueChanged event:
    void radGridView1_ValueChanged(object sender, EventArgs e)
        {
            if (radGridView1.CurrentColumn.Name == "BoolColumn")
            {
    
Completed
Last Updated: 17 Nov 2010 03:27 by ADMIN
When RadRadioButton column is bound to a column containing integer values and RadGridView is being reenabled all radio buttons are with ToggleState.On.
Completed
Last Updated: 16 Sep 2015 07:31 by ADMIN
http://screencast.com/t/mZDwbWS8

WORKAROUND:
Set the UseCompatibleTextRendering property of RadGridView to false.
Completed
Last Updated: 26 Jan 2015 15:06 by ADMIN
To reproduce:
- Add grid to a form and populate it with data.
- Show and hide the the excel like filtering several times.
Completed
Last Updated: 07 Apr 2016 12:43 by ADMIN
When scrolling to the bottom of the grid with the mouse, the last row is not lined up with the bottom of the grid. Also, when doing this, clicking on any row, leads to row jumping down to align properly, but a different row is selected.

Workaround:

public Form1()
{
    InitializeComponent();
    radGridView1.MouseDown+=radGridView1_MouseDown;
    radGridView1.MouseUp+=radGridView1_MouseUp;
}
bool scrolling = false;

private void radGridView1_MouseDown(object sender, MouseEventArgs e)
{
    ScrollBarThumb thumb = radGridView1.ElementTree.GetElementAtPoint(e.Location) as ScrollBarThumb;
    if (thumb != null)
    {
        scrolling = true;
    }
}

private void radGridView1_MouseUp(object sender, MouseEventArgs e)
{
    if (scrolling)
    {
        scrolling = false;
        int scrollBarValue = radGridView1.TableElement.VScrollBar.Value;
        radGridView1.MasterTemplate.Refresh();
        radGridView1.TableElement.VScrollBar.Value = scrollBarValue;
    }
}
Completed
Last Updated: 13 Oct 2015 11:01 by ADMIN
To reproduce:
- Set the column like this:
GridViewMaskBoxColumn col = new GridViewMaskBoxColumn();
col.Mask = "&&&&&&&&&&";
col.MaskType = MaskType.Standard;
col.FieldName = "Name";
col.TextMaskFormat = MaskFormat.IncludeLiterals;

- Type two words and press enter.

Workaround:
public class MyRadMaskedEditBoxEditor : RadMaskedEditBoxEditor
{
    public override object Value
    {
        get
        {
            if (this.MaskTextBox.Mask == "my mask")
            {
                return this.MaskTextBox.Value;
            }
            return base.Value;
        }
        set
        {
            base.Value = value;
        }
    }
}
Completed
Last Updated: 20 Oct 2015 09:04 by ADMIN
Use the following code snippet:

public Form1()
{
    InitializeComponent();

    DataTable dt = new DataTable();
    dt.Columns.Add("Id", typeof(int));
    dt.Columns.Add("Item", typeof(string));
    dt.Columns.Add("Price", typeof(decimal));

    for (int i = 0; i < 10; i++)
    {
        dt.Rows.Add(i % 5, "Item" + i, i * 2.25m);
    }

    this.radGridView1.DataSource = dt;
    GridViewDecimalColumn customCalculatedCol = new GridViewDecimalColumn("Custom Calculated Column");
    customCalculatedCol.Name = "Custom Calculated Column";
    customCalculatedCol.Expression = "SumIf(Id)";
    radGridView1.Columns.Add(customCalculatedCol);

    GridViewDecimalColumn customCalculatedCola = new GridViewDecimalColumn("Custom Col_A");         
    radGridView1.Columns.Add(customCalculatedCola);

    this.radGridView1.AutoSizeColumnsMode = Telerik.WinControls.UI.GridViewAutoSizeColumnsMode.Fill;

    Telerik.Data.Expressions.ExpressionContext.Context = new CustomExpressionContext(radGridView1);
}

public class CustomExpressionContext : Telerik.Data.Expressions.ExpressionContext
{
    private RadGridView grid;

    public CustomExpressionContext(RadGridView grid)
    {
        this.grid = grid;
    }

    public double SumIf(int currentId)
    {
        double countIf = 0;
        decimal sumIf = 0;
        foreach (GridViewRowInfo r in this.grid.Rows)
        {
            if ((int)r.Cells["Id"].Value == currentId)
            {
                countIf++;
                sumIf += (decimal)r.Cells["Price"].Value;
            }

           
        }
        return (double)sumIf;
    }
}

Workaround: invalidate the affected rows manually

private void radGridView1_CellValueChanged(object sender, GridViewCellEventArgs e)
{
    if (e.Column.Name == "Price" || e.Column.Name == "Id")
    {
        foreach (GridViewRowInfo r in this.radGridView1.Rows)
        {
            if ((int)r.Cells["Id"].Value == (int)e.Row.Cells["Id"].Value)
            {
                r.InvalidateRow();
            }
        }
    }
}
Completed
Last Updated: 13 Oct 2015 10:11 by ADMIN
To reproduce: 
- Add grid to a blank form. 
- Add summary rows and group descriptors.
- Add rows upon a button click.
- You will notice that not all rows are visible.

Workaround: 
radGridView1.TableElement.Update(GridUINotifyAction.RowHeightChanged, null);
radGridView1.TableElement.VScrollBar.Value = radGridView1.TableElement.VScrollBar.Maximum - radGridView1.TableElement.VScrollBar.LargeChange;
Completed
Last Updated: 21 Nov 2014 17:39 by Joao
To reproduce:
- Add several rows to a grid where the paging is enabled (make sure that last row has unique values)
- Use the excel like filtering in the first page, notice that the last value is missing.

Workaround:
void radGridView1_FilterPopupInitialized(object sender, FilterPopupInitializedEventArgs e)
{
    RadListFilterPopup popup = e.FilterPopup as RadListFilterPopup;
    if (popup != null)
    {
        foreach (GridViewRowInfo row in radGridView1.Rows)
        {
            var value = row.Cells[e.Column.Name].Value;
            if (!(popup.MenuTreeElement.DistinctListValues.Contains(value)))
            {
                popup.MenuTreeElement.DistinctListValues.Add(value.ToString(), value.ToString()) ;
            }
        }
    }
}