Bug 38948 - [UWP] ListViewCachingStrategy.RecycleElement Not Working
Summary: [UWP] ListViewCachingStrategy.RecycleElement Not Working
Alias: None
Product: Forms
Classification: Xamarin
Component: Windows ()
Version: 2.0.0
Hardware: PC Mac OS
: Normal normal
Target Milestone: ---
Assignee: Bugzilla
: 43299 ()
Depends on:
Reported: 2016-02-19 23:45 UTC by Jimmy [MSFT]
Modified: 2016-11-24 18:32 UTC (History)
5 users (show)

Tags: ac
Is this bug a regression?: ---
Last known good build:

repro project (80.23 KB, application/zip)
2016-02-19 23:45 UTC, Jimmy [MSFT]

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Jimmy [MSFT] 2016-02-19 23:45:00 UTC
Created attachment 15102 [details]
repro project

### Overview
ListView virtualization does not seem to work properly in UWP apps. 

### Steps to Reproduce
1. Run the attached sample

### Actual Results
The ListView’s ItemSource contains 1000 items. Using the Live Visual Tree tool in VS2015 (Debug > Windows > Live Visual Tree), you can see that the ListView is still creating objects for all items even with ListViewCachingStrategy.RecycleElement set. 

### Version Info
Tested with Forms 2.1.0-pre4

### Environment Info

Microsoft Visual Studio Professional 2015
Version 14.0.24720.00 Update 1
Microsoft .NET Framework
Version 4.7.01507

Installed Version: Professional

Visual Basic 2015   00322-40000-00000-AA362
Microsoft Visual Basic 2015

Visual C# 2015   00322-40000-00000-AA362
Microsoft Visual C# 2015

Visual C++ 2015   00322-40000-00000-AA362
Microsoft Visual C++ 2015

Windows Phone SDK 8.0 - ENU   00322-40000-00000-AA362
Windows Phone SDK 8.0 - ENU

Application Insights Tools for Visual Studio Package   1.0
Application Insights Tools for Visual Studio

ASP.NET and Web Tools 2015.1 (Beta8)   14.1.11106.0
ASP.NET and Web Tools 2015.1 (Beta8)

ASP.NET Web Frameworks and Tools 2012.2   4.1.41102.0
For additional information, visit http://go.microsoft.com/fwlink/?LinkID=309563

ASP.NET Web Frameworks and Tools 2013   5.2.30624.0
For additional information, visit http://www.asp.net/

Common Azure Tools   1.5
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

GitHub.VisualStudio   1.0
A Visual Studio Extension that brings the GitHub Flow into Visual Studio.

Microsoft Azure Mobile Services Tools   1.4
Microsoft Azure Mobile Services Tools

NuGet Package Manager   3.3.0
NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.

PreEmptive Analytics Visualizer   1.2
Microsoft Visual Studio extension to visualize aggregated summaries from the PreEmptive Analytics product.

SQL Server Data Tools   14.0.50616.0
Microsoft SQL Server Data Tools

TypeScript for Microsoft Visual Studio

Visual Studio Tools for Universal Windows Apps   14.0.24720.00
The Visual Studio Tools for Universal Windows apps allow you to build a single universal app experience that can reach every device running Windows 10: phone, tablet, PC, and more. It includes the Microsoft Windows 10 Software Development Kit.

Xamarin (dcea9c1)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin.Android (e98e962)
Visual Studio plugin to enable development for Xamarin.Android.

Xamarin.iOS (47eb74b)
Visual Studio extension to enable development for Xamarin.iOS.
Comment 1 Samantha Houts [MSFT] 2016-06-01 21:14:49 UTC
At this time, virtualization on UWP requires a fixed RowHeight.
Comment 2 qwerty2501 2016-08-05 05:24:52 UTC
"virtualization on UWP requires a fixed RowHeight."
Is this a specification of UWP?
Comment 3 Rui Marinho 2016-08-12 14:36:53 UTC
*** Bug 43299 has been marked as a duplicate of this bug. ***
Comment 4 Rui Marinho 2016-09-27 13:46:54 UTC
Should be fixed in 2.3.4-pre1
Comment 5 Parmendra Kumar 2016-11-24 18:32:46 UTC
I have checked this issue with Xamarin.Forms 2.3.4-pre1 and observed that this issue has been fixed.

Screencast: http://www.screencast.com/t/0h9rhtLB

Hence closing this issue.