2011-02-03 66 views
4

我一直在使用HtmlUnit编写Android上的网页抓取应用程序。 但是,当我构建应用程序,发生构建错误“转换为Dalvik格式失败,错误1”。 那么,如何使用HtmlUnit构建android应用程序?请...Android上的HtmlUnit

回答

3

我只是碰到了这一点,并看到了很多由XML相关的罐子引发其他错误,包括这一点:

 
[2011-05-20 12:57:50 - Android Hello] Dx 
trouble processing "javax/xml/XMLConstants.class": 

Ill-advised or mistaken usage of a core class (java.* or javax.*) 
when not building a core library. 

This is often due to inadvertently including a core library file 
in your application's project, when using an IDE (such as 
Eclipse). If you are sure you're not intentionally defining a 
core class, then this is the most likely explanation of what's 
going on. 

问题走了我删除了xalanxercesImplxml-apis jars来自项目(我通常将它们包含在桌面上使用HtmlUnit的任何项目中)。据推测他们与SDK中包含的版本相冲突。