【问题标题】:FusedLocationProviderClient could not be found in Google Play Services在 Google Play 服务中找不到 FusedLocationProviderClient
【发布时间】:2018-03-19 11:22:25
【问题描述】:

我正在尝试通过以下链接将 Google Play 服务的位置服务与 Xamarin 一起使用:

https://docs.microsoft.com/en-us/xamarin/android/platform/maps-and-location/location

IsGooglePlayServicesInstalled 函数返回 true,并且 Xamarin.GooglePlayServices.Maps 已安装。

我做错了什么?

【问题讨论】:

  • 错误日志说什么,请打印出来
  • 看起来我缺少包或命名空间。错误是:找不到类型或命名空间名称“FusedLocationProviderClient”(您是否缺少 using 指令或程序集引用?)跨度>
  • 能不能显示你正在使用的播放服务版本
  • 版本:12.2.21 (448-188803320)
  • 我已经在帖子中提到我正在关注此链接。我遵循了这些步骤,但无法定义 FusedLocationProviderClient。我认为我的 google play 服务的版本并不重要,因为当我添加 FusedLocationProviderClient 实例的定义时构建失败。

标签: android xamarin google-api google-play-services google-location-services


【解决方案1】:

解决方案是:安装 Xamarin.GooglePlayServices.Location nuget 包。

here 的文档中,他们没有提到这个包,我什至不知道它存在。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2018-12-23
    • 1970-01-01
    • 2018-02-08
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多