Bug 36995 - [Forms] Tableview Cell styles get jumbled up when scrolling quickly
Summary: [Forms] Tableview Cell styles get jumbled up when scrolling quickly
Alias: None
Product: Forms
Classification: Xamarin
Component: Android ()
Version: 2.0.0
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2015-12-14 20:34 UTC by Matthew Regul
Modified: 2017-09-15 05:14 UTC (History)
7 users (show)

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

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 for Bug 36995 on Developer Community or GitHub if you have new information to add and do not yet see a matching new report.

If the latest results still closely match this report, you can use the original description:

  • Export the original title and description: Developer Community HTML or GitHub Markdown
  • Copy the title and description into the new report. Adjust them to be up-to-date if needed.
  • Add your new information.

In special cases on GitHub you might also want the comments: GitHub Markdown with public comments

Related Links:

Description Matthew Regul 2015-12-14 20:34:47 UTC
(Observed on Android) Tableview cells get their styles jumbled by scrolling quicking (presumably do to cells being reused)

Screencast - https://dl.dropboxusercontent.com/u/62849286/Cases/240890/demo.mp4
Sample App - *See Private Comment Below*

**Steps to Reproduce:**
Run the Sample App - *See Private Comment Below*
- Scroll down to the bottom of the list
- Observe the different colors
- Scroll up and down on the page a few times
- Observe that some of the cell styles have swapped, but the text contents remains the same

**Actual Results:**
At times the wrong style is displayed inside the cells

**Expected Results:**
Correct style regardless of scrolling

**Build Date & Platform:**
- Xamarin.Forms
- Xamarin Studio (Windows) - https://gist.github.com/mattregul/dd50419746a7b7de8c24#file-xamarin-studio-version-cs
- Visual Studio 2013 - https://gist.github.com/mattregul/dd50419746a7b7de8c24#file-visual-studio-version-info-cs
Comment 3 Mihail 2015-12-16 07:19:24 UTC
I am also able to reproduce the issue. 

The problem, I think, is that every time a hidden content (a cell) is shown, the custom renderer for this row's controls (Entry, Picker, etc) is invoked and the check for oldElement == null does not pass - thus sometimes the renderer thinks that the element is a new one and renders it from scratch.