Androiddeveloper, I have met a strange problem when I want use a third party jar, it remained me that:
Dex Loader] Unable to execute dex: null
Conversion to Dalvik format failed: Unable to execute dex: null
out ofmemoryerror…An internal error occurred during: “Build Project”.
Java heap space

This is the DEX Error,I find the solutions by Google, one way is to modify the eclipse.ini, you can increase the memory allocated in eclipse.ini to this: -Xms128m -Xmx512m or something higher, but this didn’t work for me. After modify the eclipse.ini, I cannot start the eclipse. By StackOverflow, I find a solution:

eclipse.ini file must have -vm on first line and path on second line. don’t try to put everything into one line!
-vm
C:\Program Files\Java\jdk1.6.0_07\bin\javaw.exe

After add the -vm and the path in my eclipse.ini, I can start my Eclipse and the problem has been resolved.

大致解释一下上面的:

问题:

eclipse在build project的时候Conversion to Dalvik format failed: Unable to execute dex: null

解决:

在eclipse目录下打开eclipse.ini,在第一行添加

-vm
D:\Program Files\Java\jdk1.6.0_12\bin\javaw.exe

之后修改

-Xms64m
-Xms128m

-Xms128m
-Xmx512m

Another way to solve the ” Conversion to Dalvik format failed: Unable to execute dex: null” problem is using the user library, the concrete steps are as follows:
1. Right-click the project in Eclipse and select “Build Path -> Add Libraries…”.
2. Select User Library from the list and click Next.
3. Click the “User Libraries…” button.
4. Click “New…” in the User Libraries dialog.
5. Give the user library a name and select the System library checkbox and click OK.
6. Highlight the newly added user library in the list and click the “Add JARs…” button and add the desiredjar files.
7. Click OK on the User Libraries dialog.
8. Make sure the new user library is checked in the Add Library dialog and …

【Android】Tips for Android developer: “Conversion to Dalvik format failed: Unable to execute dex: null”的更多相关文章

  1. Conversion to Dalvik format failed: Unable to execute dex: null

    [2013-11-19 14:18:48 - Dex Loader] Unable to execute dex: java.nio.BufferOverflowException. Check th ...

  2. Android 报错:Conversion to Dalvik format failed: Unable to execute dex: java.nio.BufferOverflowException. Check the Eclipse log for stack trace.

    在android高版本开发环境(sdk 4.4)导入低版本(sdk 3.0)的工程时编译报错,报错信息如:Conversion to Dalvik format failed: Unable to e ...

  3. eclipse android程序运行报错:Conversion to Dalvik format failed: Unable to execute dex:

    [2013-06-19 16:59:01 - Dex Loader] Unable to execute dex: Multiple dex files define Landroid/support ...

  4. Conversion to Dalvik format failed: Unable to execute dex

    最近莫名奇妙遇到“Conversion to Dalvik format failed: Unable to execute dex”错误,stackoverflow以后得到结果 把项目中classp ...

  5. Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define ...

    Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define ... 这个错误是因为有两个相 ...

  6. Conversion to Dalvik format failed:Unable toexecute dex: method ID not in [0, 0xffff]: 65536

    关于方法数超限,Google官方给出的方案是这样的:https://developer.android.com/intl/zh-cn/tools/building/multidex.html 我也写过 ...

  7. Android开发(三十一)——重复引用包错误Conversion to Dalvik format failed

    错误:Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define Landroid/sup ...

  8. Android开发之Conversion to Dalvik format failed问题解决

    [2014-4-21 21:28:06 - Dex Loader] Unable to execute dex: java.nio.BufferOverflowException. Check the ...

  9. Conversion to Dalvik format failed with error 1(android)

    1.如果不修改android sdk版本,则使用project clean 命令作用于某工程即可. (该处理方式只是在高版本中兼容了低版本工程,未真正意义上的升级) 2.如果修改android sdk ...

随机推荐

  1. 用Cordova打包Vue-vux项目

    技术搭建:vue + vux 首先推荐阅读这篇文章,写的已经很详细了:https://www.jianshu.com/p/25d797b983cd 此处记录下我按照这篇文章打包的时候报的一些错误,方便 ...

  2. 配置国内 Docker Registry Mirror

    由于国内特殊的网络环境,往往我们从Docker Hub中拉取镜像并不能成功,而且速度特别慢. 那么我们可以给Docker配置一个国内的registry mirror,当我们需要的镜像在mirror中则 ...

  3. FTP登录提示Can't open data connection for transfer of "/"

    服务器: 系统:windows server 2008 R2 standard 是否开启防火墙:是 FTP客户端:Filezilla server 本地: FTP服务端:winscp 使用winscp ...

  4. 无备份mysql删除表后恢复

    mysql从5.6.17开始自动设置innodb_file_per_table为on,每个表设置单独表空间,数据不是集中存放在ibdata1里.下面测试下无备份后drop表后的恢复. 前奏生成数据字典 ...

  5. 定制起始url(scrapy_redis)

    爬虫:(在这里不用配置start_url,直接可以取redis里面取start_url,可以多个) from scrapy_redis.spiders import RedisSpider # cla ...

  6. Bootstrap如何配合字体自适应

    Bootstrap框架中,字体不会自适应,及时使用rem都不行,那么就只有使用媒体查询来做.这样可能会有点麻烦,但是这是我目前找到的一个方法直接上代码了 div { font-size: 12px; ...

  7. springboot第一个项目【mybatis】

    1.resources下添加spring 添加spring-context.xml,设置controller的路径,以及引入数据库配置 <beans xmlns="http://www ...

  8. Confluence 6 配置时间和日期格式

    你可以修改你 Confluence 为用户显示的时期和时间格式.设置的句法使用的是 SimpleDateFormat class,请参考 Java SimpleDateFormat 文档中的内容来设置 ...

  9. 最长上升子序列(dp)

    链接:https://www.nowcoder.com/questionTerminal/d83721575bd4418eae76c916483493de来源:牛客网 广场上站着一支队伍,她们是来自全 ...

  10. java基础概念整理(三)

    1.对象的上转型 对象的上转型不能调用和使用子类对象新增的成员和变量,不能调用子类新增的方法. 上转型对象可以访问子类继承或者隐藏的成员变量,也可以调用子类继承或者子类重写的实例方法.因此如果子类重写 ...