菜鸟想实现如题
网上都是一笔带过
1 创建java project
2 import as exiting project
可能我理解错了 project是不能包含projects的 因此一堆错误不说 还将我创建的project淹没其中
失败阿。
请懂的明示一下~~
坐等 谢谢!

解决方案 »

  1.   

    已经解决
    查找了eclipse文档
    当中写到
    When 'Use default location' is selected, the New Project Wizard will create a new project with the specified name in the workspace.
    Otherwise, you can specify the location from which the New Java Project Wizard will retrieve an existing Java project. In this case the wizard will analyze the existing project and set up the build path automatically. Click on Browse... to browse for a location of an existing Java project. 
    也就是说新建JAVA PROJECT页面中的 "location"选项,如果不check default而是指向一个路径则表示从已知工程项目导入,工具会自动搜索。但我导入后仍然出现了部分包有红叉的问题,怀疑和导入前的.classpath文件有关。网上只是说要去掉不存在的classpath。而对于存在但是没有写到.classpath文件里的路径如何处理还不知道。
      

  2.   

    直接FILE -->IMPORT-->GENERAL-->EXSITINT PROJECTS INTO WORKSPACE-->NEXT-->BROWS选择代码目录。点击FINISH。就OK了。  然后你打开项目看是Android 2.2几,还是1.几-->去创建个对应的AVD。    如果仍然有错。那么你就先创建对应的AVD,再IMPORT这个项目。
      

  3.   

    用java project也能创建 报错主要是由于找不到对应的java文件 需要把对应文件的路径加进到.classpath文件里
    比如我自己的代码就需要添加如下几行path
    <classpathentry kind="src" path="frameworks/ex/common/java"/>
    <classpathentry kind="src" path="out/target/common/obj/APPS/CalendarProvider_intermediates/src/src"/>
    <classpathentry kind="src" path="out/target/common/obj/APPS/ContactsProvider_intermediates/src/src"/>
    我的是froyo的代码,android2.2,API LEVEL 8