Unplanned
Last Updated: 08 Nov 2016 14:18 by ADMIN
To reproduce:

public RadForm1()
{
    InitializeComponent();  

    this.radGridView1.MasterTemplate.Columns.Add(new GridViewDecimalColumn("ParentId"));
    this.radGridView1.MasterTemplate.Columns.Add(new GridViewTextBoxColumn("ParentName"));
     
    this.radGridView1.MasterTemplate.Rows.Add(1, "Item" + 1);
    this.radGridView1.MasterTemplate.Rows.Add(2, "Item" + 2);
     
    this.radGridView1.MasterTemplate.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;

    for (int i = 0; i < 10; i++)
    {
        GridViewTemplate template = new GridViewTemplate();
        template.AllowAddNewRow = false;
        template.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;
        template.Caption = "Tab" + i;
        template.Columns.Add(new GridViewDecimalColumn("Id"));
        template.Columns.Add(new GridViewTextBoxColumn("Name"));
        this.radGridView1.MasterTemplate.Templates.Add(template);
        template.HierarchyDataProvider = new GridViewEventDataProvider(template);
    }
    
    this.radGridView1.RowSourceNeeded += radGridView1_RowSourceNeeded;
}

private void radGridView1_RowSourceNeeded(object sender, GridViewRowSourceNeededEventArgs e)
{
    for (int i = 0; i < 10; i++)
    {
        GridViewRowInfo row = e.Template.Rows.NewRow();
        row.Cells["Id"].Value = e.ParentRow.Cells["ParentId"].Value;
        row.Cells["name"].Value = "child row" + i;
        e.SourceCollection.Add(row);
    }
}

private void radGridView1_ViewCellFormatting(object sender, CellFormattingEventArgs e)
{
    GridDetailViewCellElement cell = e.CellElement as GridDetailViewCellElement; 
    if (cell != null)
    { 
        RadPageViewStripElement strip = cell.PageViewElement as RadPageViewStripElement;
        strip.StripButtons = StripViewButtons.LeftScroll | StripViewButtons.RightScroll; 
    }
}

If you have just one row on the master level, the strip buttons don't navigate the tabs.

Workaround:  add a dummy row that is hidden: 

private void radGridView1_RowFormatting(object sender, RowFormattingEventArgs e)
{
    if (e.RowElement.RowInfo == this.radGridView1.Rows.Last())
    {
        e.RowElement.RowInfo.Height = 1;
        e.RowElement.RowInfo.MinHeight = 1;
        e.RowElement.RowInfo.MaxHeight = 1;
    }
    else
    { 
        e.RowElement.RowInfo.Height = 25;
        e.RowElement.RowInfo.MinHeight = 25;
        e.RowElement.RowInfo.MaxHeight = 25;
    }
}
Unplanned
Last Updated: 04 Oct 2016 08:20 by ADMIN
To reproduce: please refer to the attached gif file demonstrating how to reproduce the issue with the Demo application.

Workaround: use the basic filtering.
Unplanned
Last Updated: 04 Oct 2016 06:27 by ADMIN
ADMIN
Created by: Dess | Tech Support Engineer, Principal
Comments: 0
Category: GridView
Type: Feature Request
3
Repeat the master template headers right after the end of an expanded detail template. The purpose is clarity for the end user.
Unplanned
Last Updated: 02 Sep 2016 12:28 by ADMIN
To reproduce:

public Form1()
{
    InitializeComponent();
    this.radGridView1.Columns.Add("Name");
    this.radGridView1.Columns.Add("ID");

    this.radGridView1.RowsChanged += radGridView1_RowsChanged;
}

private void radGridView1_RowsChanged(object sender, GridViewCollectionChangedEventArgs e)
{
    Console.WriteLine(e.Action);
    if (e.Action == Telerik.WinControls.Data.NotifyCollectionChangedAction.Add)
    {
        GridViewRowInfo row = e.NewItems[0] as GridViewRowInfo;
        row.Cells["ID"].Value = this.radGridView1.Rows.Count;
    }
}

private void radButton1_Click(object sender, EventArgs e)
{
    this.radGridView1.Rows.Add("Item" + this.radGridView1.Rows.Count);
}

Note: the first firing of the RowsChanged event used to be with Action=Add.
Unplanned
Last Updated: 17 Aug 2016 08:29 by ADMIN
Create a DataTable with columns Column1, Column2, Column3, Column4, Column5, and bound to RadGridView. Create a second DataTable with columns Column1, Column2a, Column3, Column4, Column5, and re-bind the RadGridView to this DataTable. Instead of the columns appearing in the same order as they are in the second DataTable, they show up as Column1, Column3, Column4, Column5, Column2a in the RadGridView. 
Unplanned
Last Updated: 05 Aug 2016 09:07 by ADMIN
To reproduce:

 Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load 
     Me.CategoriesTableAdapter.Fill(Me.NwindDataSet.Categories)

     Me.RadGridView1.DataSource = Me.CategoriesBindingSource

     Dim viewDef As New ColumnGroupsViewDefinition
     Dim group1 = New GridViewColumnGroup()
     Dim row1 = New GridViewColumnGroupRow
     group1.Rows.Add(row1)
     row1.ColumnNames.Add("CategoryID")
     row1.ColumnNames.Add("CategoryName")
     viewDef.ColumnGroups.Add(group1)

     Dim group2 = New GridViewColumnGroup()
     Dim row2 = New GridViewColumnGroupRow
     group2.Rows.Add(row2)
     row2.ColumnNames.Add("Description")
     row2.ColumnNames.Add("Picture")
     viewDef.ColumnGroups.Add(group2)

     Me.RadGridView1.ViewDefinition = viewDef
 End Sub

 Private Sub RadButton1_Click(sender As Object, e As EventArgs) Handles RadButton1.Click
     Console.WriteLine("BEFORE >>")
     For Each col As GridViewColumn In Me.RadGridView1.Columns
         Console.WriteLine(col.Name & " >> " & col.Width )
     Next

     Dim style As New GridPrintStyle()
     style.FitWidthMode = PrintFitWidthMode.FitPageWidth
     Me.RadGridView1.PrintStyle = style
     Me.RadGridView1.PrintPreview()

     Console.WriteLine("AFTER >>")
     For Each col As GridViewColumn In Me.RadGridView1.Columns
         Console.WriteLine(col.Name & " >> " & col.Width)
     Next
 End Sub

IMPORTANT: If you resize one of the columns at run time before calling the PrintPreview method, the columns' width is restored. In addition, if you call the PrintPreview method without resizing the columns before that, close the dialog and hide one of the columns by using the default context menu, the columns' width for the visible columns is enlarged.

Workaround: you can get the columns width by using the ColumnGroupRowLayout:

Dim rowLayout As ColumnGroupRowLayout = TryCast(Me.RadGridView1.TableElement.ViewElement.RowLayout, ColumnGroupRowLayout)
 
For Each col As GridViewColumn In Me.RadGridView1.Columns
    Dim info As ColumnGroupsCellArrangeInfo = rowLayout.GetColumnData(col)
    Debug.WriteLine(col.Name & " >> " & info.Bounds.Width)
Next
Unplanned
Last Updated: 05 Aug 2016 07:56 by ADMIN
To reproduce:
- Add DateTime column and set the RowHeight to 20.
- Set the theme to Windows7.
- The text is not visible when the editor is shown.

Workaround:
private void RadGridView2_CellEditorInitialized(object sender, GridViewCellEventArgs e)
{
    RadDateTimeEditor editor = e.ActiveEditor as RadDateTimeEditor;
    if (editor != null)
    {
        var element = editor.EditorElement as RadDateTimeEditorElement;
        element.Font = new Font("Segoe UI", 8, FontStyle.Regular);
        element.Children[1].Visibility = ElementVisibility.Collapsed;
        element.TextBoxElement.ShowBorder = false;        
        element.TextBoxElement.TextBoxItem.HostedControl.MinimumSize = new Size(0, 12);
    }
}
Unplanned
Last Updated: 10 May 2016 09:34 by ADMIN
To reproduce:
Search a specific text by focusing the search box programmatically and the using the SendKeys method:
private void radButton1_Click(object sender, EventArgs e)
{
    GridSearchCellElement searchCell = radGridView1.TableElement.GetCellElement(radGridView1.MasterView.TableSearchRow, null) as GridSearchCellElement;
    if (searchCell != null)
    {
        searchCell.SearchTextBox.Focus();
        searchCell.SearchTextBox.Text = string.Empty;
        SendKeys.Send("t");
        SendKeys.Send("e");
        SendKeys.Send("s");
        SendKeys.Send("t");
    }
}

Workaround: 
Repeat the search in the SearchProgressChanged event:

radGridView1.MasterView.TableSearchRow.SearchProgressChanged += TextationSearchProgressHandler;

protected void TextationSearchProgressHandler(object sender, SearchProgressChangedEventArgs e)
{
    if (e.SearchFinished && null != radGridView1.TableElement)
    {
        GridSearchCellElement searchCell = radGridView1.TableElement.GetCellElement(radGridView1.MasterView.TableSearchRow, null) as GridSearchCellElement;
        if (searchCell != null
             && searchCell.SearchTextBox.TextBoxItem.Text != e.SearchCriteria)
        {
            radGridView1.MasterView.TableSearchRow.Search(searchCell.SearchTextBox.TextBoxItem.Text);
        }
    }
}
Unplanned
Last Updated: 06 May 2016 06:15 by ADMIN
Please refer to the attached screenshot and sample video.

Workaround:
public class CustomGrid : RadGridView
{
    public override string ThemeClassName  
    { 
        get 
        { 
            return typeof(RadGridView).FullName;  
        }
    }

    protected override void OnKeyPress(KeyPressEventArgs e)
    {
        this.BeginEdit();
        if (this.GridViewElement.ActiveEditor is RadDropDownListEditor)
        {
            string symbol = e.KeyChar.ToString();
            RadDropDownListEditor editor = this.GridViewElement.ActiveEditor as RadDropDownListEditor;
            RadDropDownListEditorElement element = editor.EditorElement as RadDropDownListEditorElement;

            if ((element.AutoCompleteMode & AutoCompleteMode.Suggest) == AutoCompleteMode.Suggest)
            {
                element.EditableElementText += symbol;
                element.EditableElement.SelectionStart = 1;
                element.EditableElement.SelectionLength = 0;
            }
        }
        base.OnKeyPress(e);
    }
}
Unplanned
Last Updated: 06 May 2016 06:13 by ADMIN
To reproduce:

private void Form1_Load(object sender, EventArgs e)
{
    this.productsTableAdapter.Fill(this.nwindDataSet.Products);
    this.categoriesTableAdapter.Fill(this.nwindDataSet.Categories);
    
    radGridView1.AllowSearchRow = true;
    radGridView1.DataSource = nwindDataSet.Categories;
    radGridView1.MasterTemplate.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;
    radGridView1.UseScrollbarsInHierarchy = true;

    GridViewTemplate template = new GridViewTemplate();
    template.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;
    template.DataSource = nwindDataSet.Products;
    radGridView1.MasterTemplate.Templates.Add(template);

    GridViewRelation relation = new GridViewRelation(radGridView1.MasterTemplate);
    relation.ChildTemplate = template;
    relation.RelationName = "CategoriesProducts";
    relation.ParentColumnNames.Add("CategoryID");
    relation.ChildColumnNames.Add("CategoryID");
    radGridView1.Relations.Add(relation); 
}

Workaround:
private void radGridView1_CurrentRowChanged(object sender, CurrentRowChangedEventArgs e)
{
    if (this.radGridView1.CurrentRow != null)
    {
        if (this.radGridView1.CurrentRow.HierarchyLevel > 0)
        {
            tableElement.ScrollToRow((GridViewHierarchyRowInfo)(this.radGridView1.CurrentRow).Parent);
             this.radGridView1.TableElement.EnsureRowVisible((GridViewHierarchyRowInfo)(this.radGridView1.CurrentRow).Parent);
            tableElement.ScrollToRow(this.radGridView1.CurrentRow);
            tableElement.EnsureRowVisible(this.radGridView1.CurrentRow);
        }
    }
}


Unplanned
Last Updated: 05 Apr 2016 12:35 by ADMIN
Workaround: use custom editor element

private void radGridView1_EditorRequired(object sender, EditorRequiredEventArgs e)
{
    if (e.EditorType == typeof(RadMultiColumnComboBoxElement))
    {
        e.EditorType = typeof(MyRadMultiColumnComboBoxElement);
    }
}

public class MyRadMultiColumnComboBoxElement : RadMultiColumnComboBoxElement
{
    protected override Type ThemeEffectiveType
    {
        get
        {
            return typeof(RadMultiColumnComboBoxElement);
        }
    }

    protected override void ProcessKeyDown(object sender, KeyEventArgs e)
    {
        base.ProcessKeyDown(sender, e);

        FieldInfo fi = this.GetType().BaseType.BaseType.GetField("oldTextValue", BindingFlags.Instance | BindingFlags.NonPublic);
        fi.SetValue(this, this.textBox.Text.Substring(0, this.textBox.SelectionStart));
    }
}
Unplanned
Last Updated: 30 Mar 2016 08:13 by ADMIN
ADMIN
Created by: Dess | Tech Support Engineer, Principal
Comments: 0
Category: GridView
Type: Bug Report
1
To reproduce:

1. Add a RadGridView with a GridViewMultiComboBoxColumn. Enable the auto filter functionality for this column and add an appropriate FilterDescriptor to the RadMultiColumnComboBoxElement.
2. Using the keyboard arrows only (no mouse), navigate to the GridViewMultiComboBoxColumn.
3. Type "ba" by using the keyboard. The "b" is lost and only the "a" gets to the filter. I expect the filter to show "ba".

Workaround: use custom row behavior

public Form1()
{
    InitializeComponent();
    //register the custom row  behavior
    BaseGridBehavior gridBehavior = radGridView1.GridBehavior as BaseGridBehavior;
    gridBehavior.UnregisterBehavior(typeof(GridViewDataRowInfo));
    gridBehavior.RegisterBehavior(typeof(GridViewDataRowInfo), new CustomGridDataRowBehavior());
}

public class CustomGridDataRowBehavior : GridDataRowBehavior
{
    protected override bool ProcessAlphaNumericKey(KeyPressEventArgs keys)
    {
        bool result = base.ProcessAlphaNumericKey(keys);
        if (this.IsInEditMode &&
            (this.BeginEditMode == RadGridViewBeginEditMode.BeginEditOnKeystroke ||
             this.BeginEditMode == RadGridViewBeginEditMode.BeginEditOnKeystrokeOrF2))
        {
            if (this.GridViewElement.ActiveEditor is RadMultiColumnComboBoxElement)
            {
                this.GridViewElement.ActiveEditor.Value = keys.KeyChar;
                if (this.GridViewElement.IsInEditMode)
                {
                    RadMultiColumnComboBoxElement mccb = (RadMultiColumnComboBoxElement)this.GridViewElement.ActiveEditor;
                    RadTextBoxItem textBoxItem = mccb.TextBoxElement.TextBoxItem;
                    textBoxItem.Clear();
                    textBoxItem.Text =  keys.KeyChar.ToString();
                    textBoxItem.SelectionStart = 1;
                    textBoxItem.SelectionLength = 0;
                }

                return true;
            }
        }
        return result;
    }
}
Unplanned
Last Updated: 30 Mar 2016 08:08 by ADMIN
To reproduce:
- Add textbox and checkbox columns to a grid the checkbox column should not be visible without scrolling to the right.
- Change the data source in the FilterChanged event.
- Test this by moving the checkbox column in front of the text box column.
 
Unplanned
Last Updated: 30 Mar 2016 08:07 by ADMIN
To reproduce
- Add condition formatting object that changes the font.
- Add cell style that changes the background only.

Workaraound:
Use the CellFormatting event instead of a style.
Unplanned
Last Updated: 30 Mar 2016 08:03 by ADMIN
To reproduce:

1.Populate RadGridView with data and enable Excel-like filtering.
2.Click on a column filter icon and type in the Search textbox so more than two results appear. Then, click OK
2.The grid returns correct result.
3. Click on the previous column filter icon and navigate to Available Filters -> Contains
4. Evaluate the initial pop up dialog. Its conditions should be "Contains" and "Contains". Actually, it shows "Equals" and "Equals" according to the available filter.

Workaround:By using the CreateCompositeFilterDialog event you can replace the default CompositeFilterForm with your custom one where you can  load the selected filter operators.
Unplanned
Last Updated: 30 Mar 2016 08:02 by ADMIN
To reproduce:

GridViewMultiComboBoxColumn supplierColumn = new GridViewMultiComboBoxColumn();
supplierColumn.SyncSelectionWithText = true;
supplierColumn.Name = "SupplierColumn";
supplierColumn.HeaderText = "Supplier";
supplierColumn.DropDownStyle = Telerik.WinControls.RadDropDownStyle.DropDown;
supplierColumn.AutoCompleteMode = AutoCompleteMode.Append;
supplierColumn.DataSource = this.suppliersBindingSource;
supplierColumn.ValueMember = "SupplierID";
supplierColumn.DisplayMember = "ContactName";
supplierColumn.FieldName = "SupplierID";
supplierColumn.Width = 200;
this.radGridView1.Columns.Add(supplierColumn);

Select the new row and try to enter some text that is not valid and press Enter. You will notice the new row is added with the last valid auto-completed value.

Workaround: cancel the UserAddingRow event if the entered text is not valid.
Unplanned
Last Updated: 30 Mar 2016 08:01 by ADMIN
To reproduce:

1. Populate RadGridView with data
2. Export the grid by using the SpreadExport
3. Open the produce Excel file and select  some cells to generate a chart in Excel. You will notice that it is not possible to create a complete chart with the selected data.

Workaround: use the ExportToExcelML >> http://www.telerik.com/help/winforms/gridview-exporting-data-export-to-excel-via-excelml-format.html 
Unplanned
Last Updated: 30 Mar 2016 07:58 by ADMIN
To reproduce:

private void Form1_Load(object sender, EventArgs e)
{
    this.customersTableAdapter.Fill(this.nwindDataSet.Customers);

    GridViewMultiComboBoxColumn col = new GridViewMultiComboBoxColumn("MCCB column");
    col.DataSource = this.customersBindingSource;
    col.DisplayMember = "ContactName";
    col.ValueMember = "CustomerID";
    this.radGridView1.Columns.Add(col);
    this.radGridView1.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;
}

private void radGridView1_UserAddingRow(object sender, Telerik.WinControls.UI.GridViewRowCancelEventArgs e)
{
    if (e.Rows.First().Cells[0].Value+"" =="ALFKI")
    { 
        MessageBox.Show("Please select a product", "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
        e.Cancel = true;

        this.radGridView1.BeginEdit();
    }
}

Please refer to the attached gif file.

Workaround: use the NumericUpDown.MouseDown event and call the RadGridView.BeginEdit method instead of activating the editor in the UserAddingRow event.
Unplanned
Last Updated: 30 Mar 2016 07:58 by ADMIN
When the current cell belongs to one of the data rows and you click with the left mouse button over a GridFilterCellElement , the editor is activated. However, if you navigate with the arrow keys, the editor is not activated and the user can not see any indication about the current cell.

Workaround:

private void radGridView1_ViewCellFormatting(object sender,
    Telerik.WinControls.UI.CellFormattingEventArgs e)
{
    GridFilterCellElement filterCell = e.CellElement as GridFilterCellElement;
    if (filterCell != null)
    {
        if (filterCell.IsCurrent)
        {
            filterCell.BorderWidth = 3;
        }
        else
        {
            filterCell.BorderWidth = 1;
        }
    }
}
Unplanned
Last Updated: 30 Mar 2016 07:55 by ADMIN
Description:
When you pin data rows from the child template to PinnedRowPosition.Top, it does not affect the row. However, when you pin the certain row to PinnedRowPosition.Bottom, the behavior is correct. The same issue is detected for the header rows from the child template.