SfListView - IsScrollingEnabled = "False" causes blank SelectedItemTemplate

Hello, im currently using an sflistview with version 18.1.0.55
The sflistview has an ItemTemplate and SelectedItemTemplate
When I set the option IsScrollingEnabled  to false and select an item it goes blank 

The datatemplate of the SelectedItemTemplate has in it an SfBorder and a Grid.

Attachment: capture6_946430b7.rar

8 Replies

ED Eduardo June 7, 2020 10:59 PM UTC

Found out it happens when the sflistview is inside of a scrollview


LN Lakshmi Natarajan Syncfusion Team June 8, 2020 12:47 PM UTC

Hi Eduardo, 
 
Thank you for using Syncfusion products. 
 
We have checked the reported query “SfListView - IsScrollingEnabled = "False" causes blank SelectedItemTemplate” from our end. We could reproduce the reported issue in the Android platform from Xamairn.Forms version 4.1.0.618606 and above. We are currently analyzing the reported scenario at our side. We will analyze further and update you the details on or before June 11, 2020. We appreciate your patience until then. 
 
Regards, 
Lakshmi Natarajan 



LN Lakshmi Natarajan Syncfusion Team June 12, 2020 04:14 AM UTC

Hi Eduardo, 
 
Sorry for the delay caused. 
 
We would like to inform you that we are still analyzing the reported scenario from our side. We will check completely and update you further details on June 12, 2020. We appreciate your patience until then. 
 
Regards, 
Lakshmi Natarajan 



LN Lakshmi Natarajan Syncfusion Team June 16, 2020 07:19 AM UTC

 Hi Eduardo,  
  
We have created a new incident under your Direct trac account regarding the reported query. We suggest you to follow up with the incident for further updates. Please log in using the below link.    
  
Regards,  
Lakshmi Natarajan  



AZ Adam Zucchi November 4, 2020 09:46 PM UTC

Is there any update on this? I'm currently experiencing this as well on both iOS and Android (the data template being blank when I have an SfListView inside a ScrollView and setting the IsScrollingEnabled to false so the entire list displays).

Thanks!


LN Lakshmi Natarajan Syncfusion Team November 5, 2020 06:23 AM UTC

Hi Adam, 
 
We would like to inform you that the reported issue is a framework level issue and we have already logged issue report to the Xamarin team. Please find the issue report from the following link, 
 
 
Kindly follow up with the above framework report for further updates. 
 
Regards, 
Lakshmi Natarajan 



AZ Adam Zucchi November 5, 2020 06:46 PM UTC

There has been no activity on the GitHub issue filed with Xamarin since July, and Xamarin has closed this issue.

I have found a super hacky workaround for anyone interested (or in case it helps Syncfusion fix it behind the scenes).

The problem:
Simply setting the "IsScrollingEnabled" property to false results in an empty/blank data template for my SfListView.

My scenario:
I have a SfListView that I want to always display at its full height within a Xamarin.Forms ScrollView (hence the need for IsScrollingEnabled to be set to false per the Syncfusion documentation).  I realize that having a ListView inside of a ScrollView is frowned upon but the design I am working with requires it.  At runtime I am changing out the ItemSource of the SfListView based on user selections.  The ItemTemplate for the SfListView uses a DataTemplateSelector.  As I switch out the ItemSource after the initial load, the SfListView appears empty/blank.  I verified that the SfListView actually has ItemSource data that should be rendering.

My workaround:
After assigning the SfListView with a new ItemSource, I update a random value in my page/view model class that notifies the property changed handler of my page's code behind (xaml.cs).  When getting the property changed event in my page code behind I do the following:

this.mySyncfusionListView.IsScrollingEnabled = true;
await Task.Delay(50);
this.mySyncfusionListView.IsScrollingEnabled = false;

Note: I do *not* set IsScrollingEnabled to any value in my xaml.

I realize that the Task.Delay is gross but for some reason giving the control a moment before changing the IsScrollingEnabled property to my desired value fixes my problem and my data template is drawn just fine at run-time after numerous updates to the ItemSource.

Hopefully this helps anyone else running into this problem, and maybe Syncfusion can re-open this problem and address it.

Thanks!


LN Lakshmi Natarajan Syncfusion Team November 6, 2020 08:50 AM UTC

Hi Adam, 
 
We are very glad to have your valuable suggestions. Please get back to us at anytime if you need any other assistance. As always we will be happy to assist you. 
 
Lakshmi Natarajan 
 


Loader.
Up arrow icon