问题描述
我只是试图编译和运行示例项目:http://developer.android.com/training/location/geofencing.html
I am simply trying to compile and run the example project from: http://developer.android.com/training/location/geofencing.html
我收到以下错误:
包 com.google.android.gms.common 不存在包 com.google.android.gms.location 不存在包 android.support.v4.app 不存在
package com.google.android.gms.common does not existpackage com.google.android.gms.location does not existpackage android.support.v4.app does not exist
我已经尝试了以下方法:
I have tried the following already:
我已经下载了 Google API,请查看我的 SDK 管理器窗口的屏幕截图.
I have download Google API already, see screenshot of my SDK Manager window.
我看到了不同的相关帖子,但还没有成功编译 - 甚至尝试重新启动计算机.
I saw different related posts but have not been successful in compiling this yet - even tried restarting computer.
显示已安装 Google API 的 SDK 窗口屏幕截图:http://postimg.org/image/xf64h3fu3/
Screenshot of my SDK Window showing Google API Installed: http://postimg.org/image/xf64h3fu3/
推荐答案
您需要将 Android 支持库添加到您的项目中.
You need to add the Android Support library to your project.
http://developer.android.com/tools/support-library/设置.html
为了使用支持库,您必须在开发环境中修改应用程序项目的类路径依赖项."
"In order to use a Support Library, you must modify your application's project's classpath dependencies within your development environment."
这篇关于无法导入 com.google..... 为什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!