Forum Discussion
byme8
Nov 09, 2021Copper Contributor
Issue with upgrade Xamarin to .Net 6
I decided to try to upgrade the old Xamarin Forms app to .Net 6 and found an issue.
Error: error XFVM001: Target Framework Version is currently v6.0 and must be greater than or equal to v9.0 in order to use Material on Android.
Also, the output contains next line:
warning XA4211: AndroidManifest.xml //uses-sdk/@android:targetSdkVersion '30' is less than $(TargetFrameworkVersion) ''. Using API-31 for ACW compilation.
The new project file looks like that:
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>exe</OutputType>
<TargetFramework>net6.0-android</TargetFramework>
<TargetFrameworkVersion>v30.0</TargetFrameworkVersion>
</PropertyGroup>
</Project>
I suppose it is somehow related to Xamarin.Forms.Visual.Material. Any ideas what is wrong?
Update: I tried to use the upgrade tool, but it failed too. It was not able to find the nugets for some reason.
Update 2: Sample
- JamesMontemagno
Microsoft
Well that .NET 6 support is still in preview for iOS/Android and not officially support and probably wont be for Xamarin.Forms. I would post an issue on the github or ask on https://docs.microsoft.com/answers/products/dotnet