1.

Error:  

project cannot be built until build path errors are resolved

Cause:

没有在工程里引入android开发包

Solution:

右击选择build path ,Add library

 

2. 

Error:

r.layout.main cannnot be resolved

Cause:

默认新建project中 import android.R;

Solution:

注解掉 (//import android.R;)

Context:

Having the import android.R seems to refer to the default R.java provided by the android platform instead of the version for your application…. hence the main.xml being referred to is not found. Removing the import statement fixes the problem by causing the application to search for R.java locally.

 

 

3.

Error:

R cannot be resolved

Solution:

关掉build automatically,重新clean(貌似还有其他东西,忘掉了) O_O

 

4.

Error:

在res/draw文件夹里添加了mp3文件,在R文件里没有自动添加

Solution:

没有自动build,勾选即可

 

5.

Error:

adb 不是内如或者外部命令,也不是可运行的程序或批处理文件。

Solution:

启动模拟器,

cd到tools文件夹目录,

然后在d:

就可以使用了。

 

6.

模拟器按右Ctrl + F11不横屏,坐Ctrl才可以。

adb install <path>

 

7.    urlText = (EditText)findViewById(R.id.url_field);

Error:

R.id cannot be resolved

Solution:

android:id = "@+id/url_field" //中间不可以存在空格

posted on 2010-08-10 19:59  榆钱沽酒  阅读(253)  评论(0编辑  收藏  举报