Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/jsp/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Android Emulator和Current之间的Google Play Services版本差异_Android_Google Api_Google Play Services - Fatal编程技术网

Android Emulator和Current之间的Google Play Services版本差异

Android Emulator和Current之间的Google Play Services版本差异,android,google-api,google-play-services,Android,Google Api,Google Play Services,我一直试图简单地让我的应用程序获取用户的当前位置,但我无法通过google play services错误。我在模拟器上安装了Google API 22 x86和Google Play服务。这就是我的gradle中的依赖项 dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) compile 'com.android.support:appcompat-v7:22.2.1' compile 'com.google.and

我一直试图简单地让我的应用程序获取用户的当前位置,但我无法通过google play services错误。我在模拟器上安装了Google API 22 x86和Google Play服务。这就是我的gradle中的依赖项

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:22.2.1'
compile 'com.google.android.gms:play-services-location:7.5.+'
}
我注意到的一件事是,当我进入设置并在模拟器中查看Google Play服务的版本时,它是版本6.7.74。但是,当我尝试将依赖项切换到

compile 'com.google.android.gms:play-services-location:6.7.74'

我在代码的其他地方收到了错误。尤其是在调用与location API相关的方法时。

会出现什么错误?你能在你的模拟器上更新Google Play服务吗?@Andy错误是“更新Google Play服务。除非你更新Google Play服务,否则不会运行”。我已经在模拟器上尝试了这个版本,我的手机当前的版本,以及Google的开发网站上的7.5.0。你得到了什么错误?你能在你的模拟器上更新Google Play服务吗?@Andy错误是“更新Google Play服务。除非你更新Google Play服务,否则不会运行”。我已经在模拟器上尝试了这个版本,我的手机目前的版本,以及谷歌开发网站上的7.5.0。