2017-04-25 26 views
0

我試圖釋放一個Xamarin.Forms應用程序,但是當我更改爲Android項目的配置版本並構建時出現以下錯誤:Java.Interop.Tools.Diagnostics.XamarinAndroidException:錯誤XA2006

Java.Interop.Tools.Diagnostics.XamarinAndroidException: error XA2006: Could not resolve reference to 'System.Int32 Xamarin.Forms.Platform.Resource/String::ApplicationName' (defined in assembly 'Syncfusion.SfChart.XForms.Android, Version=13.2451.0.29, Culture=neutral, PublicKeyToken=null') with scope 'Xamarin.Forms.Platform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'. When the scope is different from the defining assembly, it usually means that the type is forwarded. ---> Mono.Cecil.ResolutionException: Failed to resolve System.Int32 Xamarin.Forms.Platform.Resource/String::ApplicationName 
     at Mono.Linker.Steps.MarkStep.MarkField(FieldReference reference) 
     at Mono.Linker.Steps.MarkStep.MarkInstruction(Instruction instruction) 
     at Mono.Linker.Steps.MarkStep.MarkMethodBody(MethodBody body) 
     at Mono.Linker.Steps.MarkStep.ProcessMethod(MethodDefinition method) 
     at Mono.Linker.Steps.MarkStep.ProcessQueue() 
     at Mono.Linker.Steps.MarkStep.Process() 
     at Mono.Linker.Steps.MarkStep.Process(LinkContext context) 
     at MonoDroid.Tuner.MonoDroidMarkStep.Process(LinkContext context) 
     at Mono.Linker.Pipeline.Process(LinkContext context) 
     at MonoDroid.Tuner.Linker.Process(LinkerOptions options, LinkContext& context) 
     at Xamarin.Android.Tasks.LinkAssemblies.Execute(DirectoryAssemblyResolver res) 
     --- End of inner exception stack trace --- 
     at Java.Interop.Tools.Diagnostics.Diagnostic.Error(Int32 code, Exception innerException, String message, Object[] args) 
     at Xamarin.Android.Tasks.LinkAssemblies.Execute(DirectoryAssemblyResolver res) 
     at Xamarin.Android.Tasks.LinkAssemblies.Execute() 
     at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute() 
     at Microsoft.Build.BackEnd.TaskBuilder.<ExecuteInstantiatedTask>d__26.MoveNext() XamarinCRM.Android  

回答

1

我們懷疑Syncfusion/Xamarin.Forms程序集之間有一些版本衝突,我們懇請您遵循以下步驟。

  1. 更新您的基本Studio進行Xamarin到最新版本(15.1.0.41)可以從以下位置下載。

    鏈接:https://www.syncfusion.com/downloads/version-history/15_1_0_41

  2. 更新您的Xamarin.Forms版本2.3.3.180。

如果您仍然面臨任何問題,請與我們聯繫。

+0

感謝您的回覆。 – Tcraft

0

我發生了同樣的錯誤信息。我能夠這樣解決: 右鍵單擊Android項目>屬性> Android選項>鏈接器,然後在鏈接屬性中選擇「無」選項。