Completed
Last Updated: 14 Jun 2018 11:20 by ADMIN
Due to browser restrictions, the print behavior is changed and works identically to the one of IE - a new tab/dialog with the grid is opened whose print command is launched. You can observe the behavior in IE at https://demos.telerik.com/aspnet-ajax/grid/examples/functionality/printing/defaultcs.aspx. 
Completed
Last Updated: 24 Jun 2022 11:21 by ADMIN
It becomes hard to see the checked checkboxes because of the selected color it has by default matches the select color of the grid

Solution:

        .RadGrid_BlackMetroTouch .rgSelectedRow .RadCheckBox.RadButton_BlackMetroTouch .rbToggleCheckboxChecked::before,
        .RadGrid_Bootstrap .rgSelectedRow .RadCheckBox.RadButton_Bootstrap .rbToggleCheckboxChecked::before,
        .RadGrid_Metro .rgSelectedRow .RadCheckBox.RadButton_Metro .rbToggleCheckboxChecked::before,
        .RadGrid_MetroTouch .rgSelectedRow .RadCheckBox.RadButton_MetroTouch .rbToggleCheckboxChecked::before {
            color: white;
        }

        .RadGrid_Glow .rgSelectedRow .RadCheckBox.RadButton_Glow .rbToggleCheckboxChecked::before,
        .RadGrid_Office2010Black .rgSelectedRow .RadCheckBox.RadButton_Office2010Black .rbToggleCheckboxChecked::before,
        .RadGrid_Telerik .rgSelectedRow .RadCheckBox.RadButton_Telerik .rbToggleCheckboxChecked::before,
        .RadGrid_WebBlue .rgSelectedRow .RadCheckBox.RadButton_WebBlue .rbToggleCheckboxChecked::before {
            color: black;
        }

Sample to reproduce the behavior and compare the default colors in other states/cases:

        <telerik:RadCheckBox runat="server" ID="rcb1"></telerik:RadCheckBox>
        <br />
        <telerik:RadCheckBox runat="server" ID="rcb2" Checked="true"></telerik:RadCheckBox>
        <telerik:RadSkinManager runat="server" ID="RadSkinManager1" Skin="Bootstrap" ShowChooser="true">
        </telerik:RadSkinManager>
        <telerik:RadFormDecorator ID="RadFormDecorator1" runat="server" DecoratedControls="All" RenderMode="Lightweight" />
        <asp:CheckBox ID="Checkbox1" Text="some checkbox" runat="server" />
        <telerik:RadGrid ID="RadGrid1" runat="server" OnNeedDataSource="RadGrid1_NeedDataSource" RenderMode="Lightweight">
            <MasterTableView>
                <Columns>
                    <telerik:GridClientSelectColumn></telerik:GridClientSelectColumn>
                    <telerik:GridTemplateColumn HeaderText="rad check box column">
                        <ItemTemplate>
                            <telerik:RadCheckBox runat="server" ID="RadCheckBox1"></telerik:RadCheckBox>
                            <br />
                            <telerik:RadCheckBox runat="server" ID="RadCheckBox2" Checked="true"></telerik:RadCheckBox>
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>
                </Columns>
            </MasterTableView>
            <ClientSettings>
                <Selecting AllowRowSelect="true" />
            </ClientSettings>
        </telerik:RadGrid>

And a dummy data source that is not a good data source in general, but it will suffice to get this running so one can observe

    protected void RadGrid1_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
    {
        (sender as RadGrid).DataSource = "abcdef";
    }
Declined
Last Updated: 17 Dec 2018 13:20 by ADMIN
RadGrid filter command is not triggered for strings containing "and" word.

Video: https://www.screencast.com/t/j649UvPQ3z6

Steps to reproduce:
Filter by "SUNBAY AND LEONA A" in the following demo:
https://demos.telerik.com/aspnet-ajax/grid/examples/functionality/filtering/excel-like-filtering/defaultcs.aspx
Completed
Last Updated: 05 Nov 2018 11:24 by ADMIN
As a temporary workaround you can use Template column with a DataField set.
Completed
Last Updated: 10 Jul 2019 14:09 by ADMIN
Hidden columns are shown on resize when the static headers and frozen column are used.

Video: https://www.screencast.com/t/4Lwuvbp7


Possible workarounds:

- Hide the column with Visible="False", instead of Display="False"

- Hide the column on the client-side:



    function gridCreated(sender, args) {
        var masterTableView = sender.get_masterTableView();
        columnIndex = masterTableView.getColumnByUniqueName("ShipName").get_element().cellIndex;
        setTimeout(function () {
            masterTableView.hideColumn(columnIndex);
        }, 2);
    }




Steps to reproduse:

            <telerik:RadGrid RenderMode="Lightweight" HeaderStyle-Width="200px"
                AutoGenerateColumns="false"
                ID="RadGrid1"
                OnNeedDataSource="RadGrid1_NeedDataSource"
                Width="100%"
                runat="server">
                <ClientSettings>
                    <Scrolling AllowScroll="True" UseStaticHeaders="true" FrozenColumnsCount="2"></Scrolling>
                </ClientSettings>
                <MasterTableView AutoGenerateColumns="false">
                    <Columns>
                        <telerik:GridBoundColumn DataField="SongID" HeaderText="SongID" FilterControlWidth="50px" HeaderStyle-Width="50px">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="SongTitle" HeaderText="Song Title" FilterControlWidth="200px"></telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="CollectionName" HeaderText="Collection Name" FilterControlWidth="200px"></telerik:GridBoundColumn>
                        <telerik:GridBoundColumn FilterControlWidth="50px" DataField="VersionID" HeaderText="VersionID" Display="false"></telerik:GridBoundColumn>
                    </Columns>
                </MasterTableView>
            </telerik:RadGrid>

Code Behind:

    protected void RadGrid1_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
    {
        (sender as RadGrid).DataSource = GetData();
    }

    private DataTable GetData()
    {
        DataTable dt = new DataTable();
        dt.Columns.Add("SongID");
        dt.Columns.Add("SongTitle");
        dt.Columns.Add("CollectionName");
        dt.Columns.Add("VersionID");

        for (int i = 0; i < 20; i++)
        {
            dt.Rows.Add(i, i + 1, i + 2, i + 3);
        }

        return dt;
    }


Unplanned
Last Updated: 26 Aug 2018 09:14 by ADMIN
With form decorator the checkboxes jump a bit to the left when cell is opened: https://www.screencast.com/t/5HwXW6kgVhb

Without form decorator they get centered because of the 100% width they get https://www.screencast.com/t/oxc75Bu6lM

It comes from the combination of two things:
- by default, the grid cells have a left padding (as well as padding to the other sides, but that's irrelevant now)
- the batch editing container does not have left padding so the editable element can better align with the text in the general case (textboxes and other editable elements usually have some left padding). With a checkbox there is no textual input, though, and so it appears to shift to the left because the left-padding of the cell is removed by the batch editing.

Workaround:

		<style>
			/* note: the margins may vary in different skins, inspect the rendering if there is a  */

			/* for form decorator */
			html .RadGrid td.rgBatchCurrent .rfdCheckboxUnchecked,
			html .RadGrid td.rgBatchCurrent .rfdCheckboxChecked,
			html .RadGrid td.rgBatchCurrent .RadCheckBoxList {
				margin-left: 12px;
			}

			/* if no form decorator */
			html .RadGrid td.rgBatchCurrent input[type='checkbox'] {
				width: auto;
				margin-left: 16px;
			}


			/* in case you have radio buttons even though they are not a supported editable control with batch editing*/
			/* for form decorator */
			html .RadGrid td.rgBatchCurrent .rfdRadioUnchecked,
			html .RadGrid td.rgBatchCurrent .rfdRadioChecked,
			html .RadGrid td.rgBatchCurrent .RadRadioButtonList{
				margin-left: 12px;
			}

			/* if no form decorator */
			html .RadGrid td.rgBatchCurrent input[type='radio'] {
				width: auto;
				margin-left: 16px;
			}
		</style>

Completed
Last Updated: 29 May 2020 16:40 by ADMIN
Created by: Alan
Comments: 1
Category: Grid
Type: Feature Request
0
Currently when doing a Batch Edit with the Grid each row and cell must be updated with a new/edited value before saving.

Example: a User has a Grid containing records and would like to update several records because a Date field requires updating.

Can it be possible for the User to select the Rows they would like to update, Edit the Date Field(using the example above), but this time when Saved all records that were selected are updated. 

This solution may require a modal to be displayed that shows all fields available, similar to Edit/Insert grid Popup. The appropriate field is then updated and saved only to selected records.

This feature would save a lot of time by not having to edit each row individually then saving.
Unplanned
Last Updated: 29 May 2020 15:58 by ADMIN
ADMIN
Created by: Peter Milchev
Comments: 0
Category: Grid
Type: Bug Report
0
If AllowPaging, AllowScroll and UseStaticHeaders are set to true, then there will be 2 empty <th> elements

workaround: 
    <ClientSettings>
...
        <ClientEvents OnGridCreated="OnGridCreated" />
    </ClientSettings>

<script>
    function OnGridCreated(sender, args) {
        var emptyth = $telerik.$(sender.get_element())
            .find("th").filter(function (ind, item) { return item.textContent == "" });
        // alert(emptyth.length)
        emptyth.append("<span style='display:none'>Hidden empty table header</span>")
    }
</script>
Declined
Last Updated: 28 Jun 2019 11:50 by ADMIN
Created by: product
Comments: 1
Category: Grid
Type: Bug Report
0
In GridTableView.cs, you provide a function
 protected virtual GridTableView CreateTableView() (Line 7828).
This function can be overloaded to return derived classes from GridTableView.

But, this is not overloadable completely. Because you create a GridTableView directly in protected void BuildDetailTablesFromDataSource() (Line 8808), too.
There you would have to call a virtual creator function, too.

This is necessary, because I have a lot of Trouble with your DataBind which I was able to fix with an overload. It is much to hard to make this bug visible for you, I really tried to do so already, but I had to fix this that way, because your GridTableView without my derivation fails in our szenario.

The call stack for that problem, I'd had to fix, is always like:
Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.IndexOutOfRangeException: Cannot find column CheckSum.
                  at System.Data.DataTable.ParseSortString(String sortString)
                  at System.Data.DataView.set_Sort(String value)
                  at Telerik.Web.UI.GridEnumerableFromDataView.PerformTransformation()
                  at Telerik.Web.UI.GridEnumerableFromDataView.TransformEnumerable()
                  at Telerik.Web.UI.GridTableView.GetEnumerator(Boolean useDataSource, GridEnumerableBase resolvedDataSource, ArrayList dataKeysArray, Boolean shouldClearDataKeys)
                  at Telerik.Web.UI.GridTableView.CreateControlHierarchy(Boolean useDataSource)
                  at Telerik.Web.UI.GridTableView.CreateChildControls(IEnumerable dataSource, Boolean useDataSource)
                  at System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data)
                  at System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data)
                  at Telerik.Web.UI.GridTableView.PerformSelect()
                  at Telerik.Web.UI.GridTableView.DataBind()
                  at Telerik.Web.UI.GridItemBuilder.BindDetailTable(GridDataItem parentItem, GridTableView cloned)
                  at Telerik.Web.UI.GridItemBuilder.BindDetailTables(GridDataItem parentItem, GridNestedViewItem detailItem)
                  at Telerik.Web.UI.GridItemBuilder.CreateItems(GridGroupingContext group)
                  at Telerik.Web.UI.GridTableView.CreateItems(IEnumerator enumerator, GridColumn[] columns, ControlCollection controls)
                  at Telerik.Web.UI.GridTableView.CreateControlHierarchy(Boolean useDataSource)
                  at Telerik.Web.UI.GridTableView.CreateChildControls(IEnumerable dataSource, Boolean useDataSource)
                  at System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data)
                  at System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data)
                  at Telerik.Web.UI.GridTableView.PerformSelect()
                  at Telerik.Web.UI.GridTableView.DataBind()


In that, your DataTableView gets an invalid sort Expression string. Therefore, I overwrote DataBind.

But this is not possible in all cases, if you create GridViewTable() objects on your own.

Best regards
Completed
Last Updated: 02 Oct 2019 14:33 by ADMIN
Exporting an empty RadGrid to XLSX or Biff with ExportSettings-ExportOnlyData="true" and Caption set, throws exception: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index

Steps to reproduce:

RadGrid markup:

<telerik:RadGrid ID="RadGrid1" runat="server" AutoGenerateColumns="true"
    OnNeedDataSource="RadGrid1_NeedDataSource">
    <ExportSettings ExportOnlyData="true">
        <Excel Format="Biff" />
    </ExportSettings>
    <MasterTableView Caption="My Personalized caption" CommandItemDisplay="Top">
        <CommandItemSettings ShowExportToExcelButton="true" />
    </MasterTableView>
</telerik:RadGrid>


C# - Code behind

protected void RadGrid1_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
{
    RadGrid1.DataSource = OrdersTable();
}
 
private DataTable OrdersTable()
{
    DataTable dt = new DataTable();
    dt.Columns.Add(new DataColumn("OrderID", typeof(int)));
    dt.Columns.Add(new DataColumn("OrderDate", typeof(DateTime)));
    dt.Columns.Add(new DataColumn("Freight", typeof(decimal)));
    dt.Columns.Add(new DataColumn("ShipName", typeof(string)));
    dt.Columns.Add(new DataColumn("ShipCountry", typeof(string)));
    dt.PrimaryKey = new DataColumn[] { dt.Columns["OrderID"] };
    return dt;
}
Unplanned
Last Updated: 07 Mar 2019 12:03 by ADMIN

When virtualization is enabled for RadGrid, NeedDataSource is called at every Post back with RebindReason = ExplicitRebind, regardless of the event target.

Steps to reproduce:

Use the following Code snippets for the runnable sample and debug the NeedDataSource event while doing post backs using other controls. For instance, you can use the RadButton1 from these snippets to make a standard Post Back.

Markup

        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        </telerik:RadAjaxManager>

        <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Skin="Default"></telerik:RadAjaxLoadingPanel>
        
        <telerik:RadButton runat="server" ID="RadButton1" Text="Postback" AutoPostBack="true" />

        <telerik:RadGrid ID="RadGrid1" runat="server" AllowPaging="false" Width="800px" OnNeedDataSource="RadGrid1_NeedDataSource">
            <MasterTableView AutoGenerateColumns="true" DataKeyNames="OrderID">
            </MasterTableView>
            <ClientSettings>
                <Scrolling AllowScroll="true" />
                <Virtualization EnableVirtualization="true" InitiallyCachedItemsCount="500" ItemsPerView="200" RetrievedItemsPerRequest="200" LoadingPanelID="RadAjaxLoadingPanel1" />
            </ClientSettings>
        </telerik:RadGrid>


C# 

    protected void RadGrid1_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
    {
        RadGrid1.DataSource = OrdersTable();
    }

    private DataTable OrdersTable()
    {
        DataTable dt = new DataTable();

        dt.Columns.Add(new DataColumn("OrderID", typeof(int)));
        dt.Columns.Add(new DataColumn("OrderDate", typeof(DateTime)));
        dt.Columns.Add(new DataColumn("Freight", typeof(decimal)));
        dt.Columns.Add(new DataColumn("ShipName", typeof(string)));
        dt.Columns.Add(new DataColumn("ShipCountry", typeof(string)));

        dt.PrimaryKey = new DataColumn[] { dt.Columns["OrderID"] };

        for (int i = 0; i < 10000; i++)
        {
            int index = i + 1;

            DataRow row = dt.NewRow();

            row["OrderID"] = index;
            row["OrderDate"] = new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day, 0, 0, 0).AddHours(index);
            row["Freight"] = index * 0.1 + index * 0.01;
            row["ShipName"] = "Name " + index;
            row["ShipCountry"] = "Country " + index;

            dt.Rows.Add(row);
        }

        return dt;
    }

Unplanned
Last Updated: 19 Apr 2019 09:41 by ADMIN

Using CommandItemTemplate (Grid - Command Item) for Editing DetailTable records and selecting an item after filtering or from another page, one item from the first page is put for editing instead. Open the attached GIF animation (EditSelectedEditWrongItem.gif) to see it in action.

 

Currently the workaround we offer is to handle the EditSelected command manually for all the DetailTables Except for the Master.

 

Grid markup:

 

        <telerik:RadGrid ID="RadGrid1" runat="server" AllowPaging="True" Width="100%" PageSize="3"
            OnItemCommand="RadGrid1_ItemCommand"
            OnDetailTableDataBind="RadGrid1_DetailTableDataBind"
            OnNeedDataSource="RadGrid1_NeedDataSource">
            <MasterTableView Name="MasterTable" AutoGenerateColumns="true" DataKeyNames="OrderID">
                <DetailTables>
                    <telerik:GridTableView Name="ChildTable" DataKeyNames="OrderID" AutoGenerateColumns="true" CommandItemDisplay="Top">
                        <CommandItemTemplate>
                            <asp:LinkButton ID="btnEditSelected" runat="server" CommandName="EditSelected" CssClass="btn btn-default">Edit Selected</asp:LinkButton>
                        </CommandItemTemplate>
                    </telerik:GridTableView>
                </DetailTables>
            </MasterTableView>
            <ClientSettings>
                <Selecting AllowRowSelect="true" />
            </ClientSettings>
        </telerik:RadGrid>

 

C# - ItemCommand

 

    protected void RadGrid1_ItemCommand(object sender, GridCommandEventArgs e)
    {
        // Logic applies for all the tables (detail tables) which are not named "MasterTable"
        if(e.Item.OwnerTableView.Name != "MasterTable" && e.CommandName == RadGrid.EditSelectedCommandName)
        {
            e.Canceled = true;

            GridTableView detailTable = e.Item.OwnerTableView;

            if (detailTable.OwnerGrid.SelectedIndexes.Count == 0)
            {
                return;
            }

            foreach (GridDataItem selectedItem in detailTable.OwnerGrid.SelectedItems)
            {
                selectedItem.Edit = true;
            }

            detailTable.Rebind();
        }
    }

 

VB - ItemCommand


Protected Sub RadGrid1_ItemCommand(ByVal sender As Object, ByVal e As GridCommandEventArgs)
    If e.Item.OwnerTableView.Name <> "MasterTable" AndAlso e.CommandName = RadGrid.EditSelectedCommandName Then
        e.Canceled = True
        Dim detailTable As GridTableView = e.Item.OwnerTableView

        If detailTable.OwnerGrid.SelectedIndexes.Count = 0 Then
            Return
        End If

        For Each selectedItem As GridDataItem In detailTable.OwnerGrid.SelectedItems
            selectedItem.Edit = True
        Next

        detailTable.Rebind()
    End If
End Sub

Unplanned
Last Updated: 02 Jan 2020 16:43 by ADMIN
Created by: Ian
Comments: 1
Category: Grid
Type: Bug Report
0
If exporting a sorted RadGrid to  Excel XLSX a white space is prepended to the header text in the output file
Unplanned
Last Updated: 02 Jan 2020 16:43 by ADMIN
Created by: David Hassan
Comments: 1
Category: Grid
Type: Bug Report
0

To replicate the problem:

  1. Create RadGrid and bind it a datasource
  2. Set ClientSettings - Selecting - AllowRowSelect to true
  3. Set ClientSettings - EnablePostBackOnRowClick to true
  4. Add a GridEditCommandColumn or a ButtonColumn with Edit/Save/Cancel CommandNames
  5. Enable AJAX for the Grid
  6. Run the application in FireFox

Clicking on the Edit button fires the RowClick event of the Grid instead of Edit/Save/Cancel.

Completed
Last Updated: 11 Dec 2020 14:56 by ADMIN
Release R1 2021
When exporting to Excel XLSX while there are hidden columns at the end of the columns collection and an unused ColumnGroup, the application throws the exception of: Index was out of range. Must be non-negative and less than the size of the collection
Unplanned
Last Updated: 01 Aug 2019 18:12 by ADMIN
When you have both a Detail Item Template and a Detail Table inside a Grid and then when you show a hidden column using the context menu it only shows for the first row and the grid doesn't display properly.  It also throws the javasecript error "Unable to get property '_getVisibleColumnsCount' of undefined or null reference".
Unplanned
Last Updated: 02 Jan 2020 16:32 by ADMIN

Issue seems to happen with RadGrid with Bootstrap Skin, RenderMode Lightweight when RequireFieldValidator is enabled in combination with Batch Editing.

Unexpected look (Bootstrap skin):

Other skins seems to have it right.

Expected look (Default skin):

Expected look (Silk skin):


 

Unplanned
Last Updated: 23 Dec 2019 09:27 by ADMIN

I have a Telerik RadGrid, and there is a date column on the grid layout. The date format I am using to display date values is "dd/MM/yyyy". Then, I export that grid data to Excel file with GridExcelExportFormat.Biff type. The problem here is when I open the newly exported Excel file, the date format is changed to "MM/dd/yyyy". 

I want to keep displaying my date format "dd/MM/yyyy" in the Excel file after exporting the grid data.

Completed
Last Updated: 03 Sep 2019 12:00 by ADMIN
Hi, we are having a problem with the column picker, we are trying to move columns and they are getting "stuck". 

The same issue happens in the Telerik online demo page https://demos.telerik.com/aspnet-ajax/grid/mobile-examples/overview/default.aspx?name=overview

1. Open the above page using the latest google chrome

2. Open dev tools and pick mobile browser iPhone 5/SE (note: problem also happens on Android)

3. Click the ||| icon on the top right

4. Drag a column up or down using the hamburger icon (3 horizontal lines)

5. It gets stuck
Completed
Last Updated: 10 Oct 2019 15:19 by ADMIN

I found issue here in your forum and received an updated fix.

However, the sample fix has the grid name ("RadGrid1") hard-coded in the method "function OnClientHidden(sender, args)". In our code we need to use this for many grids; each with its own name. Please show me how to obtain the grid name generically; preferably from the arguments (sender, args).

Also in the example the checkbox isn't explicitly declared; I assume the code is using some implicit name. However, in our code the name of the checkbox is declared (see below my signature). Please show me how to change the code to use different checkbox names.