C# 在Xamarin Android应用程序中包含Amazon S3 Nuget会导致FileNotFoundException
当我将Amazon S3 Nuget软件包添加到我的xamarin android应用程序时,出现以下错误:C# 在Xamarin Android应用程序中包含Amazon S3 Nuget会导致FileNotFoundException,c#,amazon-s3,xamarin.android,nuget,C#,Amazon S3,Xamarin.android,Nuget,当我将Amazon S3 Nuget软件包添加到我的xamarin android应用程序时,出现以下错误: Severity Code Description Project File Line Suppression State Error Exception while loading assemblies: System.IO.FileNotFoundException: Could not load assembly 'System.Net.Http
Severity Code Description Project File Line Suppression State
Error Exception while loading assemblies: System.IO.FileNotFoundException: Could not load assembly 'System.Net.Http.Primitives, Version=1.5.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. Perhaps it doesn't exist in the Mono for Android profile?
File name: 'System.Net.Http.Primitives.dll'
at Xamarin.Android.Tuner.DirectoryAssemblyResolver.Resolve(AssemblyNameReference reference, ReaderParameters parameters)
at Xamarin.Android.Tasks.ResolveAssemblies.AddAssemblyReferences(ICollection`1 assemblies, AssemblyDefinition assembly, Boolean topLevel)
at Xamarin.Android.Tasks.ResolveAssemblies.Execute() ContentUpdater
你知道怎么解决这个问题吗
尼克
更新:刚刚在Windows 10通用应用程序中尝试了相同的方法,我得到了这个结果
Severity Code Description Project File Line Suppression State
Error Cannot resolve Assembly or Windows Metadata file 'System.Net.Http.Primitives.dll' WindowsContentUpdater C:\devoctomy\GitHub\ContentUpdater\WindowsContentUpdater\WindowsContentUpdater.csproj
S3库是坏了还是怎么了 有点晚了,但我设法把它修好了
从异常来看,似乎您需要Http客户端库。你能试着回答这个问题吗?我已经看过那条线了,不幸的是,它没有起到任何作用。我认为amazon sdk有问题,因为它甚至不能与通用windows 10应用程序一起工作,在添加引用后,我收到了大量的警告。。“严重性代码描述项目文件行抑制状态警告检测到包降级:Microsoft.NETCore.UniversalWindowsPlatform从5.2.2降级到5.1.0 WindowsContentUpdaterObjectLibrary(>=1.0.0)->AWSSDK.S3(>=3.3.3)->Microsoft.NETCore.UniversalWindowsPlatform(>=5.2.2)WindowsContentUpdaterObjectLibrary(>=1.0.0)->Microsoft.NETCore.UniversalWindowsPlatform(>=5.1.0)0“现在,我决定从一个Windows窗体应用程序和一个标准的.net类库开始,当我的代码正常工作时,我会将它移植到一个可移植的类库中。我怀疑AWS S3库可能需要更新?我发现Kvandike开发的一个名为BasicAWS的小库,它编译得很好,所以现在可能是一个解决方案。谢谢,直接添加Microsoft.Net.Http nuget就足以解决我的问题了!