Forum Xamarin.Forms

Could not load assembly 'Xamarin.Android.Support.Fragment, Version=


I have updated my Xamarin forms version to

Portable projects build, but the Droid project fails to build with the following error message...

Severity Code Description Project File Line Suppression State
Error Exception while loading assemblies: System.IO.FileNotFoundException: Could not load assembly 'Xamarin.Android.Support.Fragment, Version=, Culture=neutral, PublicKeyToken='. Perhaps it doesn't exist in the Mono for Android profile?
File name: 'Xamarin.Android.Support.Fragment.dll'
at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.Resolve(AssemblyNameReference reference, ReaderParameters parameters)
at Xamarin.Android.Tasks.ResolveAssemblies.AddAssemblyReferences(DirectoryAssemblyResolver resolver, ICollection`1 assemblies, AssemblyDefinition assembly, Boolean topLevel)
at Xamarin.Android.Tasks.ResolveAssemblies.Execute(DirectoryAssemblyResolver resolver) Quantum.Droid C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets 1446

Here are my VS and SDK versions:

Microsoft Visual Studio Enterprise 2017 Version 15.4.5
Xamarin (34c1b6c)
Xamarin.Android SDK (HEAD/c2a33d8ea)
Xamarin.iOS and Xamarin.Mac SDK (51128b8)

Is there something extra I need to do to get this to build with the latest version?

Please help...

Best Answer


  • bytebuilderbytebuilder USMember ✭✭

    thanks @WilliamWatterson . This worked for me!

    FYI, there's another solution posted here: in case other people prefer that one:

  • anish_palanish_pal INMember ✭✭

    After updating the latest Xamarin.Forms from nuget this works fine too.

  • ArunPrasad.007ArunPrasad.007 USMember ✭✭

    @WilliamWatterson said:
    Found my issue. I didnt have the target framework version for the droid project set properly. I had selected framework 6 - so I increased this to "latest" and updated the XamarinForms nuget package again. and it builds ok now.

    Yes, This will work perfectly.

Sign In or Register to comment.