Bug 60968 - UnHandledException throws while View has been customizing from Layout<View> and loaded inside StackLayout
Summary: UnHandledException throws while View has been customizing from Layout<View> a...
Alias: None
Product: Forms
Classification: Xamarin
Component: Forms ()
Version: 2.4.0
Hardware: PC Windows
: Normal major
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2017-12-04 12:05 UTC by Ashok
Modified: 2018-03-22 10:05 UTC (History)
6 users (show)

Tags: exception, crash, uwp, layout, ac
Is this bug a regression?: ---
Last known good build:

Sample (316.81 KB, application/x-zip-compressed)
2017-12-04 12:05 UTC, Ashok
ScrollView issue (316.90 KB, application/x-zip-compressed)
2018-03-22 10:04 UTC, Ganesan VG

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 60968 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 Ashok 2017-12-04 12:05:36 UTC
Created attachment 25897 [details]

I have created custom view derived from Layout<View> and loaded that view inside StackLayout but the application get crashed in Xamarin.Forms.UWP, same has been working in Xamarin.Forms.Android.

Run the attached sample in Xamarin.Forms.UWP,

You will get the exception details "Object reference not set to an instance of an object".
Comment 1 Paul DiPietro [MSFT] 2017-12-10 22:57:44 UTC
Thanks for the reproduction and will mark as confirmed until further investigation can be made into the cause.
Comment 2 Ganesan VG 2018-01-25 04:11:56 UTC
Similarly, if we load the custom view inside grid with row definition as Auto, the custom view is not loaded in iOS platform but if same is loaded with row definition as *, it loads as expected.

So, Could you please check with these too?

PS: The issue gets replicated in the same attachment sample. 

Replication Procedure:

Step 1: Open the sample and comment the StackLayout and load the CustomView in a grid with row definition as Auto.
Step 2: Run the application in iOS platform.

Issue : CustomView is not loaded.

Dinesh B
Comment 3 Ganesan VG 2018-03-22 10:04:28 UTC
Created attachment 26224 [details]
ScrollView issue
Comment 4 Ganesan VG 2018-03-22 10:05:44 UTC
Hi ,

Same UnHandledException throws while View has been customizing from Layout<View> and loaded inside ScrollView. I have attached the sample , please check it.