If an earlier version of ndroid (such as 1.5) is put into a later version (such as 2.2), the preceding error may occur. The solution is as follows:
1. If you do not modify the android sdk version, use the project clean command to act on a project.
(This processing method is only compatible with lower-version projects in the high version and is not truly upgraded)
2. To modify the android sdk version, follow these steps:
1) modify the SDK
Select the project, build path --> configure build path ---> library to delete the referenced low-version SDK,
Add External JARs, select SDK of later version, OK, and save
2) modify the classpath File
This file may contain this item: <classpathentry kind = "lib" path = "Your specified High Version address"
Change her to <classpathentry kind = "con" path = "com. android. ide. eclipse. adt. ANDROID_FRAMEWORK"/>
3) Modify AndroidManifest. xml
In the AndroidManifest. xml file, add the <uses-sdk android: minSdkVersion = "3"> </uses-sdk>
4) Modify default. properties (important)
Target = android-3 in the last line of the file (not used in the previous step), and save it as target = android-8.
Let's take a look at your project and the new android 2.2 project structure.
3. conversion to dalvik format failed with error 1 Solution
You can use Project ---------> clean to easily solve many problems that occur when developing Android projects in eclipse.
However, if the Android library cannot be found, or the Android system library is accidentally removed, how can I re-Add the Android system library?
In Java Build Path in eclipse, you cannot add a defined system library such as Android 2.1. While I try to manually add
The Android. jar in the SDK folder has the Conversion to Dalvik format failed with error 1 problem. Tossing
After that, many netizens said that using Project clean can solve the problem, but it is useless for me.
Find the solution on Baidu:
Modify the project classpath file.
<! -- Note that the. classpath file is stored in the hard disk of the eclipse workspace in the directory of the project. -->
<Classpathentry kind = "lib" path = "Custom jar address"/>
Modify
<Classpathentry kind = "con" path = "com. android. ide. eclipse. adt. ANDROID_FRAMEWORK"/>.
In this way, the project is refreshed, And the Android system library Android 2.1 is back, and the error is also solved.
Bytes --------------------------------------------------------------------------------------------------------------------------
Project-> properties-> android label, check a target from the project build target list
<! -- In this case, the error cannot be removed. Note that after you enter project> properties> android
A is library item, check it, and click OK to solve the error.
And the subsequent methods cannot be solved. Finally, I can see an is library item. Check it and try again. The error is gone -->
========================================================== ==========================================
Appendix:
Solution to widespread Internet access: conversion to dalvik format failed with error 1
If an android earlier version Project (such as android 1.5) is placed in a later version environment (such as android 2.2), the preceding error may occur. The solution is as follows:
1. If the android sdk version is not modified, use the project clean command to act on a project. (This Processing Method
It is only compatible with lower-version projects in the high version and has not been upgraded in the real sense)
2. to modify the android sdk version, perform the following steps:
1) modify the SDK
Select the project, build path --> configure build path ---> library to delete the referenced low-version SDK,
Add External JARs, select SDK of later version, OK, and save
2) modify the classpath File
This file may contain this item: <classpathentry kind = "lib" path = "Your specified High Version address"
Change her to <classpathentry kind = "con" path = "com. android. ide. eclipse. adt. ANDROID_FRAMEWORK"/>
3) Modify AndroidManifest. xml
In the AndroidManifest. xml file, add the <uses-sdk android: minSdkVersion = "3"> </uses-sdk>
4) Modify default. properties (important)
Target = android-3 in the last line of the file (not used in the previous step), and save it as target = android-8.
Let's take a look at your project and the new android 2.2 project structure.