This is from our production app. Cannot reproduce it, don't know exactly when or why it happens; we just have crashes logged to have happened to 9 users in the past year with a total of 30 occurences.
These are unhandled UWP exceptions, which mean that our app goes poof :)
System.ArgumentException: Value does not fall within the expected range at
System.ThrowHelper.ThrowAddingDuplicateWithKeyArgumentException(Object) + 0xf at
Telerik.UI.Xaml.Controls.Data.ListView.Model.BaseLayoutStrategy.RecycleLocally() + 0x320 at Telerik.UI.Xaml.Controls.Data.ListView.Model.BaseLayoutStrategy.MeasureContent(RadSize, Double, Double) + 0xd at Telerik.UI.Xaml.Controls.Data.ListView.Model.LayoutController.MeasureVertical(RadSize) + 0x1b9 at Telerik.UI.Xaml.Controls.Data.ListView.Model.LayoutController.MeasureContent(RadSize) + 0x42 at Telerik.UI.Xaml.Controls.Data.ListViewModel.MeasureContent(RadSize) + 0x2e at Telerik.UI.Xaml.Controls.Data.RadListView.OnContentPanelMeasure(RadSize) + 0x17f at Telerik.UI.Xaml.Controls.Data.ListView.ListViewPanel.MeasureOverride(Size) + 0x60 at Windows.UI.Xaml.FrameworkElement.global::Windows.UI.Xaml.IFrameworkElementOverrides.MeasureOverride(Size) + 0x26
System.ArgumentException: An item with the same key has already been added at
System.ThrowHelper.ThrowAddingDuplicateWithKeyArgumentException(Object) + 0xf at Telerik.UI.Xaml.Controls.Data.ListView.Model.BaseLayoutStrategy.RecycleLocally() + 0x320 at Telerik.UI.Xaml.Controls.Data.ListView.Model.BaseLayoutStrategy.MeasureContent(RadSize, Double, Double) + 0xd at Telerik.UI.Xaml.Controls.Data.ListView.Model.LayoutController.MeasureVertical(RadSize) + 0x1b9 at Telerik.UI.Xaml.Controls.Data.ListView.Model.LayoutController.MeasureContent(RadSize) + 0x42 at Telerik.UI.Xaml.Controls.Data.ListViewModel.MeasureContent(RadSize) + 0x2e at Telerik.UI.Xaml.Controls.Data.RadListView.OnContentPanelMeasure(RadSize) + 0x17f at Telerik.UI.Xaml.Controls.Data.ListView.ListViewPanel.MeasureOverride(Size) + 0x60 at Windows.UI.Xaml.FrameworkElement.global::Windows.UI.Xaml.IFrameworkElementOverrides.MeasureOverride(Size) + 0x26
when we try to add a dynamic AutomationId in each item of the list (something like AutomationId="{Binding Id}"), the AutomationId is not provided to the elements we see in the appium inspector.
Works with fixed values
When using a RadListview with a Grid or a Stack Layout in iOS I get the following exception. I haven't tested using the stacklayout outside of the RadListView nor have I tested it outside of the ItemTemplateSelector
Telerik.XamarinForms.Common.NotRegisteredRendererException: There is no renderer registered for the specified type: Xamarin.Forms.Grid
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:telerikDataControls="clr-namespace:Telerik.XamarinForms.DataControls;assembly=Telerik.XamarinForms.DataControls"
xmlns:telerikListView="clr-namespace:Telerik.XamarinForms.DataControls.ListView;assembly=Telerik.XamarinForms.DataControls"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:d="http://xamarin.com/schemas/2014/forms/design"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:models="clr-namespace:AlertTest.Models"
mc:Ignorable="d"
xmlns:views="clr-namespace:AlertTest.Views"
x:Class="AlertTest.Views.MainPage">
<ContentPage.Resources>
<ResourceDictionary>
<DataTemplate x:Key="NonDivisibleTemplate">
<Grid>
<StackLayout Orientation="Vertical" Padding="10" Spacing="0" BackgroundColor="Yellow" InputTransparent="True" Unfocused="StackLayout_Unfocused">
<Label Text="{Binding ItemText}"/>
</StackLayout>
</DataTemplate>
<DataTemplate x:Key="DivisibleTemplate">
<Grid>
<StackLayout Orientation="Vertical" Padding="15" Spacing="0" BackgroundColor="White" Unfocused="StackLayout_Unfocused">
<Label Text="{Binding ItemText}" FontSize="Large" HorizontalTextAlignment="Center"/>
<Label Text="{Binding ItemText}" FontSize="Small" FontAttributes="Italic" TextColor="Gray"/>
</StackLayout>
</Grid>
</DataTemplate>
<models:MyDataTemplateSelector
x:Key="MyTemplateSelector"
NonDivisibleTemplate="{StaticResource NonDivisibleTemplate}"
DivisibleTemplate="{StaticResource DivisibleTemplate}" />
</ResourceDictionary>
</ContentPage.Resources>
<StackLayout VerticalOptions="StartAndExpand">
<!-- Place new controls here -->
<views:FloatingLabelEntry EntryText="{Binding EntryText}" Margin="20" BackgroundColor="Yellow" PlaceholderText="{Binding PlaceholderText}"/>
<Entry TextChanged="Entry_TextChanged" BackgroundColor="AliceBlue" Margin="20"/>
<telerikDataControls:RadListView x:Name="listView" ItemsSource="{Binding ListItems}" ItemTemplateSelector="{StaticResource MyTemplateSelector}" SelectionMode="Single" IsItemSwipeEnabled="False" >
<!--<telerikDataControls:RadListView.ItemSwipeContentTemplate>
<DataTemplate>
-->
<!--<Grid Margin="0"
Padding="0"
ColumnSpacing="0"
RowSpacing="0">-->
<!--<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>-->
<!--
<StackLayout Orientation="Horizontal" HorizontalOptions="FillAndExpand">
<Label BackgroundColor="#2474d2"
HorizontalTextAlignment="Start"
HorizontalOptions="StartAndExpand"
Text="Mark as read"
TextColor="White"
VerticalTextAlignment="Center" />
<Label Grid.Column="2"
BackgroundColor="Red"
HorizontalTextAlignment="End"
HorizontalOptions="EndAndExpand"
Text="delete"
TextColor="White"
VerticalTextAlignment="Center"/>
</StackLayout>
-->
<!--</Grid>-->
<!--
</DataTemplate>
</telerikDataControls:RadListView.ItemSwipeContentTemplate>-->
</telerikDataControls:RadListView>
</StackLayout>
</ContentPage>
Telerik RadListView with two Columns - they are Thumbnails with a tap gesture. When we change the Spancount to 1 there is no right border line but when set back to 2 it shows as the screenshot on IOS,
The issue happens on iPhone 11, XR, devices with a notch, and when ListViewGridLayout is with SpanCount="2".
Workaround: Set the background color of the ListViewItemStyle to Transparent
<telerikDataControls:RadListView.ItemStyle>
<telerikListView:ListViewItemStyle BorderWidth="0"
BackgroundColor="Transparent"/>
</telerikDataControls:RadListView.ItemStyle>
Hello, could you provide some guidance about the following situation....
I have a scenario using the RadListView that implements a PropertyGroupDescriptor for a property attached to my ObservableCollection<T>, where the property that it is monitoring is string value. The dataset is designed that it may have only one grouping before an item is selected them the dataset will have two different groupings. One the data changes, the ListView updates to show that there are two different groups but the group header doesn't change and neither does the cell content. If I click on the GroupHeader of the new section, then it updates to reflect the change in data. Is there a way to get the data to change in the Listview with some kind of Refresh so it stays up to date with the data.
Seeing it on iOS right now.
Thanks
After I updated to `2021.1216.1-hotfix` (to solve this problem in Android and Google Material) the RadListView's LoadOnDemand automatic stopped working
Workaround:
I've had to downgrade Xamarin.Google.Android.Material to v1.1.0.5 and use the latest stable release of Telerik UI v2021.1.119.1 which restored the functionality.
Changing a property on an item that is involved with grouping and sorting and then removing and re-adding the item to the collection results in the list being in an invalid state (e.g. duplicate items, incorrect template, etc.)
Error message can be reproduced on iPhone 11 Simulator iOS 13.6
[UICollectionView] Invalid update: invalid number of items in section 0. The number of items contained in an existing section after the update (4) must be equal to the number of items contained in that section before the update (4), plus or minus the number of items inserted or deleted from that section (1 inserted, 0 deleted) and plus or minus the number of items moved into or out of that section (0 moved in, 0 moved out). - will perform reloadData. UICollectionView instance: <TKCollectionView: 0x7f8525b86600; baseClass = UICollectionView; frame = (0 0; 414 725); clipsToBounds = YES; autoresize = W+H; gestureRecognizers = <NSArray: 0x600001232bb0>; layer = <CALayer: 0x6000019b0520>; contentOffset: {0, 0}; contentSize: {414, 453}; adjustedContentInset: {0, 0, 0, 0}; layout: <TKListViewLinearLayout: 0x7f8524f5e400>; dataSource: <Telerik_XamarinForms_DataControlsRenderer_iOS_TKExtendedListView: 0x7f8524f5b590; frame = (0 0; 414 725); layer =
<CALayer: 0x6000019b03a0>>>; currentUpdate: [UICollectionViewUpdate - 0x7f8526897fc0: old:<UICollectionViewData: 0x6000025f4000> new<UICollectionViewData: 0x6000025f47e0> items:<(
"I(0,3)"
)>]