c# - Xamarin Studio : Cannot copy System. Diagnostics.Tools.dll,因为源文件不存在

标签 c# android xamarin xamarin.forms xamarin-studio

我是 Xamarin 的新手,即使在较小的事情上仍然很努力。 :)

已开发可在 iOS 和 Android 中运行的 Xamarin.Forms 应用。

我添加了Android定位服务的代码。 为此,请点击以下链接: 1. http://developer.xamarin.com/guides/android/platform_features/maps_and_location/location/ 2. https://blog.xamarin.com/introducing-the-google-play-services-component-for-xamarin-android/

但是,发现了很多错误,因为我使用 Android SDK 管理器添加的 google play 服务是最新的。 在为如何使用 SDK 管理器或命令行获取旧版本以及在何处获取旧版本绞尽脑汁几个小时后,发现 Xamarin 确实在 xamarin 商店提供组件,该商店具有 Google Play Services 组件。我将它的 22.0.0 版本添加到项目的组件文件夹中。

在那之后,我所有与 google play 服务相关的错误都消失了,但开始出现以下错误:

Cannot copy System.Diagnostics.Tools.dll to /bin/Debug/System.Diagnostics.Tools.dll, as the source file doesn't exist.

(为了便于阅读,我截断了dll路径)

我的问题是:

  1. 如何解决 dll 问题?
  2. 无论我采取什么措施来修复 Google Play 服务,它们是否足够好?还是我需要在 IDE 中多加注意?
  3. 添加 Google play 服务是否与 DLL 问题有关?

最佳答案

  1. 我重新启动了 xamarin studio,它为我修复了 DLL 问题。
  2. 按照上述步骤将 Google Play 服务添加到项目中。添加 Google Play 服务与 DLL 问题无关。因此,继续面对其他问题;)

关于c# - Xamarin Studio : Cannot copy System. Diagnostics.Tools.dll,因为源文件不存在,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32091858/

相关文章:

C# 错误 CS1061 : Type `System.Collections.Generic.List<int>' does not contain a definition for `Length'

c# 在类方法中添加 "this"可选

c# - User.Identity.Name 在 asp.net core + Angular 客户端应用程序中为 null

java - 查找日期列表中的所有年份

ios - 如何在iphone单独安装的应用程序中打开ppt、excel等文件?

C# 创建一个列表来保存基类的任何派生子项

android - Robolectric 自定义影子代码

android - Google Mobile Vision API 无法检测纵向模式下的文本

android - 如何在 Android 上的 Chrome 中打开然后自动关闭 OAuth 页面?

visual-studio - Visual Studio 2017 中的 Xamarin.iOS 项目给出自动配置错误