Java.Lang.NullPointerException in Previewer for Visual Studio 2019 for CollectionView

njsokalskinjsokalski Member ✭✭✭

I am trying to use a CollectionView in my Xamarin.Forms project, but the CollectionView gives a Java.Lang.NullPointerException in the Visual Studio 2019 previewer. This happens even before I attempt to set any of the CollectionView attributes or properties. What is the problem?


  • LandLuLandLu Member, Xamarin Team Xamurai

    It seems CollectionView can't be correctly displayed on the XAML Previewer. I also got a null reference exception here:

    However, it can be displayed with the right item template when I deployed the project on the simulators. If you want to debug the collection view try to deploy to the simulators or real physical devices.

Sign In or Register to comment.