Reputation: 93
While rebuilding my android project it shows this error:
System.IO.FileNotFoundException: Could not load assembly 'Xamarin.Android.Support.Fragment,
Version=1.0.0.0, Culture=neutral, PublicKeyToken='. Perhaps it doesn't exist in the Mono for Android profile?
Then I installed 'Xamarin.Android.Support.Fragment' but it fails to install and shows this error:
Unable to resolve dependencies. 'Xamarin.Android.Support.v4 23.3.0' is not compatible with
'Xamarin.Android.Support.Design 23.3.0 constraint: Xamarin.Android.Support.v4 (= 23.3.0)',
'Xamarin.Forms 2.5.0.91635 constraint: Xamarin.Android.Support.v4 (>= 25.4.0.2)'
How to solve this problem?
I am using API Version 15 (Android 4.0.3). After installing API Version 25 (Android 7.1) it shows the same error.
Upvotes: 1
Views: 2459
Reputation: 33993
It seems the new NuGet packages are built agains MonoAndroid80. You might want to change you 'Compile using' option to the latest Android version.
To do this, go into your Android project properties by right-clicking on the project node and selecting 'Properties'. There under 'Application', set the 'Compile using Android version' to the appropriate version or latest. Here shown in Visual Studio.
If the version you are looking for is not present, install newer SDK versions through the Android SDK Manager.
See also this link
Upvotes: 1