Completed
Last Updated: 11 Mar 2020 09:16 by ADMIN
Release 2.9.0
Robert
Created on: 05 Mar 2020 13:17
Category: Grid
Type: Bug Report
0
System.ArgumentOutOfRangeException: Index was out of range when hiding a grid from its SelectedItemsChanged handler
This worked in 2.7.1
6 comments
ADMIN
Marin Bratanov
Posted on: 11 Mar 2020 09:16

Hello Wayne, Robert,

Our upcoming 2.9.0 release will have this fixed (I am attaching a screenshot that shows how you can tell). At the moment, the plan is to release it next week.

 

Regards,
Marin Bratanov
Progress Telerik

 UI for Blazor
Robert
Posted on: 11 Mar 2020 08:27
If it's a option, you could revert to version 2.7.1. The bug is not present in that version.
Grant
Posted on: 11 Mar 2020 00:36

Hi,

Anytime frame when this will hit public release? I am hitting it again and it causes the SignalR channel to close and render the app useless.

If there is a hotfix or something we can do inside the event handler to trap the error from crashing SignalR would be much appreciated.

ADMIN
Marin Bratanov
Posted on: 06 Mar 2020 08:58

Indeed.

To add a small clarification on the two threads - this page here is in our Feedback Portal that is basically an issue tracker. The other thread is in the public forums, so it is not a private ticket and anyone can see it.

So, for anyone needing to monitor the status of this bug - click the Follow button on this page here.

 

Regards,
Marin Bratanov
Progress Telerik

 UI for Blazor
Grant
Posted on: 06 Mar 2020 00:04
This is the same as my logged ticket.
ADMIN
Marin Bratanov
Posted on: 05 Mar 2020 13:18

This is logged for review.

Here's a sample reproducible for anyone else hitting a similar issue:

@if (IsVisible)
{
    <TelerikButton OnClick="@( _ => IsVisible = false )">hide without error</TelerikButton>
    <span>Select an item to hide with error</span>
    <Telerik.Blazor.Components.TelerikGrid Data="Items"
                                           SelectionMode="Telerik.Blazor.GridSelectionMode.Single"
                                           SelectedItemsChanged="OnItemsChanged"
                                           ScrollMode="Telerik.Blazor.GridScrollMode.Scrollable"
                                           TItem="MyModel">
        <GridColumns>
            <Telerik.Blazor.Components.GridColumn Field="Name"></Telerik.Blazor.Components.GridColumn>
        </GridColumns>
    </Telerik.Blazor.Components.TelerikGrid>
}
<TelerikButton OnClick="@( _ => IsVisible = true)">show</TelerikButton>



@code  {

    public MyModel ModelData { get; set; }
    public List<MyModel> Items { get; set; }

    protected override void OnInitialized()
    {
        ModelData = new MyModel();
        Items = new List<MyModel>();
        for (var i = 0; i < 1000; i++)
        {
            Items.Add(new MyModel()
            {
                Name = "Name " + i
            });
        }
    }

    public bool IsVisible { get; set; } = true;

    public void OnItemsChanged(IEnumerable<MyModel> items)
    {
        IsVisible = false;
    }

    public void ShowGrid()
    {
        IsVisible = true;
    }

    public class MyModel
    {
        public string Name { get; set; }

    }
}

 

Regards,
Marin Bratanov
Progress Telerik

 UI for Blazor