Skip to content

Collection View Header and Empty View not showing on Android when ItemSource is null #8934

@3steve3

Description

@3steve3

Description

If the data the CollectionView is bound to is null, then CollectionView.Header and CollectionView.Empty View is not visible. This issue was also tested on the Windows version and the bug does not appear.
A sample of the issue can be found here https://github.com/3steve3/EmptyCollectionViewBug

Steps to Reproduce

  1. Create a new .Net Maui project
  2. Create a viewmodel for the view
  3. Create a Collection View in the View.
  4. Bind the Collection View item source to null variable, CollectionView.Header and CollectionView.EmptyView will not be visible on Android.

Version with bug

6.0.400

Last version that worked well

Unknown/Other

Affected platforms

Android

Affected platform versions

Android 12

Did you find any workaround?

No

Relevant log output

No response

Metadata

Metadata

Assignees

Labels

area-controls-collectionviewCollectionView, CarouselView, IndicatorViewfixed-in-8.0.0-preview.7.8842Look for this fix in 8.0.0-preview.7.8842!p/1Work that is important, and has been scheduled for release in this or an upcoming sprintplatform/androids/triagedIssue has been revieweds/verifiedVerified / Reproducible Issue ready for Engineering Triaget/bugSomething isn't working

Type

No type
No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions