This is a migrated thread and some comments may be shown as answers.

DynamicGridVirtualizationStrategy issue

2 Answers 23 Views
DataBoundListBox
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Karol
Top achievements
Rank 1
Karol asked on 07 Apr 2015, 12:17 PM

Hello,

I created DataboundListBox with DynamicGridVirtualizationStrategy to get similar layout like pinterest. Unfortunatelly I've got a problem with very fast scrolling up. After so fast scroll this class raises an expcetion: ArgumentException: Item with the same key is already added. This error comes from PositionRealizedItemBottom method when we adding associatedItemData hash code. 

Here is my xaml:

<telerikPrimitives:RadDataBoundListBox DataVirtualizationMode="None"
                            ItemsSource="{Binding Model.Items}"
                            ScrollViewer.VerticalScrollBarVisibility="Hidden"
                            CacheMode="BitmapCache"
                            IsAsyncBalanceEnabled="True"
                            ListFooterDisplayMode="WithDataItems"
                            Margin="18,0">
<telerikPrimitives:RadDataBoundListBox.ItemTemplate>
<DataTemplate>
...
</DataTemplate>
</telerikPrimitives:RadDataBoundListBox.ItemTemplate>
<telerikPrimitives:RadDataBoundListBox.ItemLoadingTemplate>
<DataTemplate>
<telerikPrimitives:RadBusyIndicator AnimationStyle="AnimationStyle9"
                                    IsRunning="True"
                                    Content=""
                                    Foreground="White"
                                    Margin="0,6,0,0" />
</DataTemplate>
</telerikPrimitives:RadDataBoundListBox.ItemLoadingTemplate>
<telerikPrimitives:RadDataBoundListBox.EmptyContentTemplate>
<DataTemplate>
<StackPanel VerticalAlignment="Center">
    <telerikPrimitives:RadBusyIndicator Foreground="White"
                                        Margin="0,6,0,0"
                                        AnimationStyle="AnimationStyle7"
                                        IsRunning="True"
                                        Content="{Binding LocalizedResources.PreparingContent, Source={StaticResource LocalizedStrings}}" />
</StackPanel>
</DataTemplate>
</telerikPrimitives:RadDataBoundListBox.EmptyContentTemplate>
<telerikPrimitives:RadDataBoundListBox.ListFooterContent>
<Grid Height="200" />
</telerikPrimitives:RadDataBoundListBox.ListFooterContent>
<telerikPrimitives:RadDataBoundListBox.VirtualizationStrategyDefinition>
<telerikPrimitives:DynamicGridVirtualizationStrategyDefinition Orientation="Horizontal"
                                                            StackCount="2" />
</telerikPrimitives:RadDataBoundListBox.VirtualizationStrategyDefinition>
</telerikPrimitives:RadDataBoundListBox>

2 Answers, 1 is accepted

Sort by
0
Karol
Top achievements
Rank 1
answered on 07 Apr 2015, 03:58 PM
Sorry this issue is found in Windows Phone 8 Controls. 
0
Tsvyatko
Telerik team
answered on 10 Apr 2015, 06:38 AM
Hi Karol,

Thank you for contacting us! We have tried to reproduce the issue on several devices in different scenarios, but with no success. Would it be possible to share some additional information regarding the structure of Item data template as well as the data. Alternatively, you could modify the project attached to reflect the original scenario and reproduce the issue described.

Regards,
Tsvyatko
Telerik
 

See What's Next in App Development. Register for TelerikNEXT.

 
Tags
DataBoundListBox
Asked by
Karol
Top achievements
Rank 1
Answers by
Karol
Top achievements
Rank 1
Tsvyatko
Telerik team
Share this question
or