Reputation: 13
on starting a new xamarin forms project and just adding Plugin.MediaManager.Forms v1.1.1 then rebuilding it produces error:
Unknown option -RC:\Users\Hp..\flat\values-en-rIN_values-en-rIN.arsc.flat
. Please check $(AndroidAapt2CompileExtraArgs)
and $(AndroidAapt2LinkExtraArgs)
to see if they include any aapt
command line arguments that are no longer valid for aapt2
and ensure that all other arguments are valid for aapt2
.
The Line CrossMediaManager.Current.Init(); has been added in constructor. The error occurs only if i add MediaManager. Ive tried with MediaManager 0.9.7 till 1.1.1 No improvement
Earlier with VS2019 it was working fine.
Upvotes: 0
Views: 70
Reputation: 13
finally i got it enter the following in the Android csproj file
<PackageReference Include="Xamarin.AndroidX.MediaRouter" Version="1.2.0" />
<PackageReference Include="Xamarin.AndroidX.Palette" Version="1.0.0.5" />
...
in the item group which contains xamarin.forms, xamarin.essentials etc
Upvotes: 0