“Conversion to Dalvik format failed with error 1” on external JAR

前端 未结 30 2416
抹茶落季
抹茶落季 2020-11-21 07:32

In my Android application in Eclipse I get the following error.

UNEXPECTED TOP-LEVEL EXCEPTION:
java.lang.IllegalArgumentException: already add

30条回答
  •  不思量自难忘°
    2020-11-21 07:44

    None of the listed solutions worked for me.

    Here's where I was having a problem:

    I added the jSoup external JAR file to my project's path by first putting it in a source folder called "libs", and then right clicking on it, Build Path -> add to build path. This threw the Dalvik conversion error. It said I had "already included" a class from that JAR file. I looked around the project's directory and found that the place where it was "already included" was in fact the bin directory. I deleted the JAR file from the bin directory and refreshed the project in Eclipse and the error went away!

提交回复
热议问题