1、android 错误信息解决方案总结Android开发错误信息与解决方案汇总【错误信息】2011-01-19 16:39:10 - ApiDemos WARNING: Application does not specify an API level requirement!2011-01-19 16:39:10 - ApiDemos Device API version is 8 (Android 2.2)原因:不影响正常运行。在AndroidManifest.xml文件中没有加API的版本号,在 之间加2011-01-19 16:55:04 - ApiDemos Installation
2、error: INSTALL_FAILED_INSUFFICIENT_STORAGE2011-01-19 16:55:04 - ApiDemos Please check logcat output for more details.2011-01-19 16:55:05 - ApiDemos Launch canceled!该设备没有足够的存储空间来安装应用程序,【错误信息】2011-02-18 11:46:53 Failed to push selection: Is a directory原因:原先目录已经有pkg_3.apk的文件夹,再copy一个pkg_3.apk安装文件时出现问题,
3、解决办法,先删除掉pkg_3.apk的文件夹2011-03-04 09:25:12 - ActivityMain: DxUNEXPECTED TOP-LEVEL EXCEPTION:java.lang.IllegalArgumentException: already added: Lorg1/apache/commons/codec/net/RFC1522Codec;2011-03-04 09:25:12 - ActivityMain: Dx at com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:123)2
4、011-03-04 09:25:12 - ActivityMain: Dx at com.android.dx.dex.file.DexFile.add(DexFile.java:143).2011-03-04 09:25:12 - ActivityMain: Dx1 error; aborting2011-03-04 09:25:12 - ActivityMain Conversion to Dalvik format failed with error 1原因:【错误信息】启动Eclipse时出现:this android sdk requires android developer to
5、olkit version 10.0.0 or above.current version is 8.0.1.v201012062107-82219.please update adt to the latest version原因:Eclipse的Android开发插件版本过低,应该下载ADT-10.0.0,并且1. 启动 Eclipse, 然后进入 Help Install New Software.2. 在 Available Software 对话框里,点击 Add.【错误信息】2011-03-09 15:21:34 - Info Failed to install Info.apk
6、on device ?: Unable to open sync connection!2011-03-09 15:21:34 - Info java.io.IOException: Unable to open sync connection!2011-03-09 15:21:34 - Info Launch canceled!原因:关闭模拟器和eclipse,执行adb kill-server命令,然后重试一下【错误信息】调用Webservice时出现.SocketException: Permission denied (maybe missing INTERNET permission
7、)原因:需要访问到网络,所以,在AndroidManifest.xml中,需要进行如下配置:原因:Eclipse的Android开发插件版本过低,应该下载ADT-10.0.0,并且1. 启动 Eclipse, 然后进入 Help Install New Software.2. 在 Available Software 对话框里,点击 Add.【错误信息】2011-03-09 15:21:34 - Info Failed to install Info.apk on device ?: Unable to open sync connection!2011-03-09 15:21:34 - In
8、fo java.io.IOException: Unable to open sync connection!2011-03-09 15:21:34 - Info Launch canceled!原因:关闭模拟器和eclipse,执行adb kill-server命令,然后重试一下【错误信息】调用Webservice时出现.SocketException: Permission denied (maybe missing INTERNET permission)原因:需要访问到网络,所以,在AndroidManifest.xml中,需要进行如下配置:【错误信息】org.xmlpull.v1.X
9、mlPullParserException: expected: START_TAG http:/schemas.xmlsoap.org/soap/envelope/Envelope (position:START_TAG 2:603 injava.io.InputStreamReader44a3a7b0)原因有可能是以下2个之一:1)Webservice服务器的Soap版本为1.0,所以客户端指定SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);VER11改为VER10
10、2)String serviceUrl = http:/200.200.200.11:10000/nqbx/service/InqBxWebService?wsdl;Url指的是你的webservice的地址.一般都是以*.wsdl或者*.?wsdl结束的.但是.需要注意的是.要去掉后面的.wsdl或者.?wsdl【错误信息】在新的线程中 public class HttpThread extends Thread .增加一个弹出窗体:new AlertDialog.Builder(this).setTitle(数据加载失败).setMessage(请检查网络连接情况) .setPositiv
11、eButton(OK, new DialogInterface.OnClickListener() public void onClick(DialogInterface dialoginterface, int i) ).show(); 原因及解决办法:/不能在线程中操作UI界面java.lang.RuntimeException: Cant create handler inside thread that has not called Looper.prepare()修改后:new AlertDialog.Builder(com.nantsing.infoquery.chuanbo_de
12、tail.this).setTitle(数据加载失败).setMessage(请检查网络连接情况) .setPositiveButton(OK, new DialogInterface.OnClickListener() public void onClick(DialogInterface dialoginterface, int i) 【错误信息】The constructor AlertDialog.Builder(chuanbo_detail.HttpThread) is undefined原因及解决办法:在UI主线程之外是无法对UI组件进行控制的。因为你必须在新线程任务完成之后利用各
13、种方法先UI主线程发送消息通知任务完成从而来显示各种提示消息。线程间通信方法有多种,常用的是用handler来传递消息。如下:线程中构造消息:/构造消息Message message = handle.obtainMessage();Bundle b = new Bundle();b.putString(tag, 1);message.setData(b);handle.sendMessage(message);另外自定义消息: /* * 捕获消息队列 fubin.pan 2011-04-02 */Handler handler = new Handler() public void hand
14、leMessage(Message m) if (!m.getData().getString(tag).equals(1) .elsenew AlertDialog.Builder(chuanbo_detail.this).setTitle(数据加载失败).setMessage(请检查网络连接情况!) .setPositiveButton(OK, new DialogInterface.OnClickListener() public void onClick(DialogInterface dialoginterface, int i) ).show();【错误信息】android低版本工
15、程(如1.5)放到高版本环境中(如2.2)可能会上述错误,解决方法如下:1。 如果不修改android sdk版本,则使用project clean 命令作用于某工程即可。 (该处理方式只是在高版本中兼容了低版本工程,未真正意义上的升级)2。 如果修改android sdk版本,则需要以下几个步骤: 1)修改SDK 选择工程,build path - configure build path - library 删除引用的低版本SDK, 然后add External JARs,选择高版本SDK,OK,保存 2)修改classpath文件 该文件可能存在该项: classpathentry ki
16、nd=lib path =你所指定的高版本的地址 把她修改成 3) 修改AndroidManifest.xml 在AndroidManifest.xml文件中,application标签后添加 4) 修改default.properties(很重要) 该文件最后一行(前面没用#的)target=android-3 该成target=android-8,保存。 再看看你的工程和新建的android 2.2的工程结构就一样了。【错误信息】在线程debug(运行没有问题)时调用Webservice时出现:JDI thread evaluations has encountered a problem
17、Exception processing async thread queue Exception processing async thread queueJDI thread evaluations 原因及解决办法:与运行无关的错误,关掉expressions视图就可以了【错误信息】打开开源项目JavaEye Android client时出错http:/javaeye-android-这是 JavaEye 网站基于 Android 平台的客户端软件,可用以阅读动静、帖子、闲谈, 收躲, RSS 等功用。2011-04-19 10:55:11 - JavaEye Android Clien
18、t Project has no default.properties file! Edit the project properties to set one.原因及解决办法:遇到这种情况,可以创建一个default.properties文件,如果创建之后还是有错误,那么delete这个project,重新import。编辑default.properties 之后,一般会自动创建 gen 目录, 如果没有,也可尝试手工创建。Adroid Adapter ADB Interface 严重错误今天在配置完Eclipse和Android SDK开发环境之后,想用华为C8500手机通过USB连接电
19、脑,并在手机上去调试,但莫名其妙出现Adroid Adapter ADB Interface 安装严重错误,在豌豆荚手机精灵安装驱动的时候,也出现这个错误,后面也莫名奇妙的多装几次就好了,还没找到什么原因。【错误信息】用手机调试运行出现:ActivityManager: Warning: Activity not started, its current task has been brought to the front原因及解决办法:该手机已经启动了相同名字的应用,关闭之后再试!【错误信息】最近(2012-04-05)在打开SDK Manager.exe,更新SDK时,会出现如下错误: F
20、ailed to fetch URL https:/dl-reason: Connection timed out: connect原因及解决办法:dl-在大陆封掉了解决方法就是修改C:WindowsSystem32driversetchosts文件。添加一行:74.125.237.1 dl-保存,重新启动SDK Manager.exe【错误信息】2012-04-08 17:42:24 - JavaEye Android Client -2012-04-08 17:42:24 - JavaEye Android Client Android Launch!2012-04-08 17:42:24
21、 - JavaEye Android Client The connection to adb is down, and a severe error has occured.2012-04-08 17:42:24 - JavaEye Android Client You must restart adb and Eclipse.2012-04-08 17:42:24 - JavaEye Android Client Please ensure that adb is correctly located at C:androidandroid-sdk-windowsplatform-tools
22、adb.exe and can be executed.原因及解决办法:查看任务管理器,关闭所有adb.exe重启eclipse即可【错误信息】更新SDK时错误信息:Site AuthenticationPlease login to the following .原因及解决办法:Cancel跳过提示【错误信息】打开Eclipse 提示安装ADT 17原因及解决办法:最新的Android SDK只能安装ADT 17.0.0可用的下载地址:这里可不能用常规方法安装这个 ADT 17.0.0.zip 文件, 首先得解压这个文件,将里面的文件夹覆盖掉Eclipse安装目录下的文件夹。然后再用Help
23、- install new software-Add - Name: ADT Archive:选择ADT 17.0.0.zip【错误信息】安装ADT 17.0.0时,提示:Your original request has been modified. Android DDMS is already installed, so an update will be performed instead. Android Development Tools is already installed, so an update will be performed instead. Android Hi
24、erarchy Viewer is already installed, so an update will be performed instead. Android Traceview is already installed, so an update will be performed instead.Cannot complete the install because one or more required items could not be found. Software being installed: Android Development Tools 17.0.0.v2
25、01203161636-291853 (com.android.ide.eclipse.adt.feature.group 17.0.0.v201203161636-291853) Missing requirement: Android Development Tools 17.0.0.v201203161636-291853 (com.android.ide.eclipse.adt.feature.group 17.0.0.v201203161636-291853) requires org.eclipse.core.runtime 3.6.0 but it could not be fo
26、und原因及解决办法:【错误信息】Updates ADT 17.0.0时提示:Cannot complete the install because one or more required items could not be found. Software being installed: Android Development Tools 17.0.0.v201203161636-291853 (com.android.ide.eclipse.adt.feature.group 17.0.0.v201203161636-291853) Missing requirement: Andro
27、id Development Tools 17.0.0.v201203161636-291853 (com.android.ide.eclipse.adt.feature.group 17.0.0.v201203161636-291853) requires org.eclipse.core.runtime 3.6.0 but it could not be found原因及解决办法:requires org.eclipse.core.runtime 3.6.0 but it could not be foundrequires org.eclipse.ui 3.6.0 but it coul
28、d not be foundeclipse需要升级到3.6.0,我的版本是3.5.2【错误信息】2012-04-09 17:14:49 - Info -2012-04-09 17:14:49 - Info Android Launch!2012-04-09 17:14:49 - Info Connection with adb was interrupted.2012-04-09 17:14:49 - Info 0 attempts have been made to reconnect.2012-04-09 17:14:49 - Info You may want to manually restart adb from the Devices view.原因及解决办法:重新启动eclipse【错误信息】2012-04-10 09:45:49 - adb ADB server didnt ACK2012-04-10 09:45:49 - adb * failed to start daemon *原因及解决办法:查看任务管理器,关闭所有adb.exe重启eclipse【错误信息】2012-04-10 09:53:50 - ApiDemos -2012-04-10 09:53:50 - ApiDemos Android Launch!2012-0
copyright@ 2008-2022 冰豆网网站版权所有
经营许可证编号:鄂ICP备2022015515号-1