Is there a way to fix error: 'Xamarin.Forms recommends TargetPlatformMinVersion >= 10.0.17763.0 (current project is -1)'

Viewed 5603

I have a problem when I want to upgrade a Xamarin app from Android 9.0 to Android 10.

/Users/user/.nuget/packages/xamarin.forms/4.8.0.1269/buildTransitive/Xamarin.Forms.targets(5,5): 
Warning: Xamarin.Forms recommends TargetPlatformMinVersion >= 10.0.14393.0 (current project is -1) (WeatherApp)

The error is on this part of the code:

 <Warning
    Text="Xamarin.Forms recommends TargetPlatformVersion &gt;= 10.0.17763.0 (current project is $(MicrosoftUIXamlTargetPlatformCheckValue))"
    Condition="$(MicrosoftUIXamlTargetPlatformCheckValue) &lt; 17763" />

I want to run this app on Android 10, but every clean build and run app on a real Android device app not responding every time.

2 Answers

There is a similar thread here.

And the Solution is:

I can confirm the issue has been fixed on the latest version of Xamarin.Forms (4.8.0.1687). It is the SP5.

I recommend to update the nuget package.

I have been facing similar issue in release mode after lot of search I have found the fix that worked for me

Setting up the build configurations under configuration mapping to release worked for me

make sure all the release configuration build is checked under configuration mapping.

Related