Bug 26038 - Can't run Xamarin.Forms application on iOS 6.1
Summary: Can't run Xamarin.Forms application on iOS 6.1
Alias: None
Product: Forms
Classification: Xamarin
Component: Forms ()
Version: 1.3.1
Hardware: Other Linux
: --- normal
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2015-01-14 16:39 UTC by joshcomley@googlemail.com
Modified: 2015-02-13 22:19 UTC (History)
4 users (show)

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 on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description joshcomley@googlemail.com 2015-01-14 16:39:36 UTC
I am using the new unified API and attempting to build a brand new app for an iPhone 3GS running iOS 6.1.6 (10B500). I am using SDK 7.1 (although also tried SDK 8.1), and my target version is set to 6.1. I have the both 7.1 and 8.1 SDK installed on my build host.

However, whatever I seem to do I get null reference exceptions throughout the API and the app just crashes out.

According to the following Xamarin "Introduction to Xamarin.Forms" link Xamarin.Forms supports "iOS 6.1 or higher":


Is there something obvious that I am missing? What changes do I need to make to enable a brand new Xamarin.Forms project to run on iOS 6.1?

I am using Visual Studio 2013 and Visual Studio 2015 (tried creating brand new Xamarin.Forms projects in both and just ran the template without any modifications other than "Deployment Target" and SDK version) and I have no luck.

Here is an example exception I get:

System.ArgumentNullException: Argument cannot be null. Parameter name: uiFontTextStyle at UIKit.UIFont.GetPreferredFontForTextStyle (Foundation.NSString uiFontTextStyle) [0x00017] in /Developer/MonoTouch/Source/monotouch/src/build/native/UIKit/UIFont.g.cs:120 at UIKit.UIFont.get_PreferredHeadline () [0x00000] in /Developer/MonoTouch/Source/monotouch/src/UIKit/UIFont.cs:32 at Xamarin.Forms.Platform.iOS.ResourcesProvider.UpdateStyles () [0x00000] in :0 at Xamarin.Forms.Platform.iOS.ResourcesProvider.GetSystemResources () [0x00000] in :0 at Xamarin.Forms.Application..ctor () [0x00000] in :0 at Ios61TestClassic.App..ctor () [0x00000] in c:\Users\Josh\Documents\Visual Studio 2013\Projects\Ios61TestClassic\Ios61TestClassic\App.cs:12 at Ios61TestClassic.iOS.AppDelegate.FinishedLaunching (UIKit.UIApplication app, Foundation.NSDictionary options) [0x00007] in c:\Users\Josh\Documents\Visual Studio 2013\Projects\Ios61TestClassic\Ios61TestClassic.iOS\AppDelegate.cs:26 at (wrapper managed-to-native) UIKit.UIApplication:UIApplicationMain (int,string[],intptr,intptr) at UIKit.UIApplication.Main (System.String[] args, IntPtr principal, IntPtr delegate) [0x00005] in /Developer/MonoTouch/Source/monotouch/src/UIKit/UIApplication.cs:62 at UIKit.UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName) [0x0001c] in /Developer/MonoTouch/Source/monotouch/src/UIKit/UIApplication.cs:45 at Ios61TestClassic.iOS.Application.Main (System.String[] args) [0x00002] in c:\Users\Josh\Documents\Visual Studio 2013\Projects\Ios61TestClassic\Ios61TestClassic.iOS\Main.cs:19
Comment 1 Brendan Zagaeski (Xamarin Team, assistant) 2015-01-14 17:37:40 UTC
Thanks for the report! This issue is under active investigation by the Xamarin.Forms team. The plan at the moment is that it should be fixed in the next Xamarin.Forms release.

Just to be diligent about record keeping I'll add a link here to a duplicate internal (private) bug that's being used to track the issue:

I'll update this public bug report with any additional updates as they become available.
Comment 2 Brendan Zagaeski (Xamarin Team, assistant) 2015-02-13 22:19:52 UTC
As indicated by the updated "strikethrough" style of the link to the private bug in comment 1, this issue should now be resolved (as of Xamarin.Forms 1.3.2 and later).

If you find conditions that reproduce the error message from comment 0 after upgrading to Xamarin.Forms 1.3.2 or later, feel free to attach a new test case to this bug report, and I will reopen it.