【问题标题】:Trouble deploying release version of Xamarin.Android app部署 Xamarin.Android 应用程序的发布版本时遇到问题
【发布时间】:2013-05-09 02:06:14
【问题描述】:

当应用程序使用 Xamarin Release 运行工具在模拟器上完成安装时,我收到以下错误。

GREF GC Threshold: 1800

Unhandled Exception:
System.Net.WebException: Error: NameResolutionFailure
  at System.Net.HttpWebRequest.EndGetResponse (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 
  at CallRestService.Activity1.<OnCreate>m__0 (IAsyncResult ar) [0x00000] in <filename unknown>:0 
  at System.Net.WebAsyncResult.CB (System.Object unused) [0x00000] in <filename unknown>:0 

模拟器运行的是 Android 2.3.3,从 Xamarin 编译器运行的 Debug 构建运行良好。

关于为什么会发生这种情况以及如何解决这个问题的任何提示?

【问题讨论】:

  • when the app finishes installing on the emulator... 您是在运行应用程序之前收到此错误,还是您的意思是在安装结束时点击运行然后收到错误?
  • 我的意思是,当应用程序被提示你在模拟器上运行时,安装后立即。
  • 其实我刚刚修复了这个错误。我必须在解决方案的 Android 应用程序首选项上将 Android 清单添加到项目中,并选中面板的所需权限部分下的“Internet”框。

标签: c# android xamarin


【解决方案1】:

有同样的问题。通过将&lt;uses-permission android:name="android.permission.INTERNET" /&gt; 添加到清单来解决。

【讨论】:

  • 我设置了 Internet 权限,但仍然出现同样的错误。
猜你喜欢
  • 2016-08-27
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2022-11-03
  • 2017-05-03
  • 2021-04-21
  • 2021-01-19
  • 2011-08-30
相关资源
最近更新 更多