eclipse android不能导入google play服务库 [英] eclipse android can not import google play services library

查看:177
本文介绍了eclipse android不能导入google play服务库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,我对Android开发非常新鲜,我想学习如何使用Google Maps API v2。在尝试了许多教程之后,我总是看起来与Google Play服务库有问题。不知何故,Eclipse无法正确导入。我尝试过本教程 https://github.com/thecodepath/android_guides/wiki / Google-Maps-Fragment-Guide ,当我尝试将Google Play服务项目作为图书馆加入时,首先它会很好和顺利,我在Project Properties - Android - Library窗口中点了一个绿色的勾号,但是当我关闭它,我仍然得到很多不能解决一个类型的错误。我回到我添加图书馆的窗口,我看到一个红色的X和项目下的问号,而不是绿色的勾号。我尝试了几个其他教程,我总是有这个库的问题。我喜欢这个教程,我真的想让它工作。我也尝试手动复制工作区中的库文件夹,但也不起作用。我喜欢疯狂地尝试找到一个答案,但我总是发现我以前尝试过的东西(如在工作区中手动复制库或类似的东西)。我很绝望,我真的不知道为什么不能看到图书馆请帮忙。另外这是我第一次发布到StackOverflow,所以要温柔:)

hello i am quite new to Android development and i want to learn how to use the google Maps API v2. After trying numerous tutorials, i always seem to have a problem with the google play services library. Somehow, Eclipse can't import it properly. I tried this tutorial https://github.com/thecodepath/android_guides/wiki/Google-Maps-Fragment-Guide and when i try to include Google Play Services project as a library, first it all goes nice and smooth, i get a green tick in the Project Properties - Android - Library window, but when i close it i still get lots of "can't be resolved to a type" errors. I return to the window where i add the library and i see a red "X" and a question mark under "project" instead of the green tick. I tried several other tutorials and i always have a problem with this library. I like this tutorial and i would really like to make it work. I also tried to manually copy the library folder in the workspace but that didn't work either. I googled like crazy trying to find an answer but i always find something that i tried before (like manually copying the library in the workspace or something similar). I am quite desperate, i really have no idea why it can't just see the library please help. Also this is my first post to StackOverflow so be gentle :)

稍后编辑(已解决):
当我导入下载的项目,我保持在桌面,这就是为什么它不工作,我把它复制在工作区的一切工作。非常感谢您帮助初学者:)

later Edit (solved): when i imported the downloaded project, i kept it on the desktop and thats why it didn't work, after i copied it in the workspace everything worked. Thank you all very much for helping a beginner :)

推荐答案

在eclipse中添加库的重要事情是记住,项目和图书馆项目需要在同一个工作区。

The important thing in adding a library in eclipse is to remember that your project and the library project need to be in the same workspace.

要解决以下方法,请执行以下操作:

To solve this follow below ways,

您可以将 google-play-services 库项目复制到您的主要项目所在的同一工作区。

You can copy the google-play-services library project to the same workspace where your main project is there.

否则

将库导入eclipse时,请记住检查将项目复制到工作区中,这将添加库的副本到你的工作区。

While importing the library to eclipse remember to check copy projects into workspace which will add a copy of the library to your workspace.

这篇关于eclipse android不能导入google play服务库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆