After Eclipse updates the Android SDK, the new project appears appcompat_v7project related issues

Source: Internet
Author: User

After Eclipse updates the Android SDK, there are a variety of issues with new projects. Online all kinds of solutions, have a long time, summed up a bit.

1. Appears error:error retrieving parent for item:no Resource found that matches the given name ' Android:Widget.Material.Action Button '

After you create a new project. Appears error:error retrieving parent for item:no Resource found that matches the given name ' Android:Widget.Material.ActionBu Tton '


This is when you create a new project. The Target SDK and compile with did not select the latest API21 caused.

Workaround 1: Create a new project again, Target SDK and compile with both select API21:



Workaround 2:

Right--properties the APPCOMPAT_V7 project and your newly created project, respectively. Select Android-project Build target to select Android 5.0, note: The Library of the APPCOMPAT_V7 project is the library to be selected.




2. Missing Appcompat_v7\bin\appcompat_v7.jar file

Suppose your target SDK and compile with are API21, but the resulting project still has an error. Say the missing Appcompat_v7\bin\appcompat_v7.jar file, what you see:


You will find the project created well after. Workspace column In addition to the "Test" project we created, there is a package called "Appcompat_v7", and the package shows an error (red X). The "Hello" package displays a red exclamation mark.


The solution is: Click on the menu bar "Project", select "Clean", then click "OK", clean finished, you will find the APPCOMPAT_V7 package error, hello packet red warning problem has been overcome.


3. Error parsing Data for Android-21 failed

Let's say you're using the latest Android 5.0 SDK, but when you open eclipse, the error parsing Data for Android-21 failed:


Workaround: Upgrade jdk! The original version number of the Java1.6 does not meet the requirements. You need to upgrade to the 1.7 or 1.8 version number.


Although I'm not quite sure, it's just that after the Android SDK is updated, the tool loads the appcompat_ after the new project V7project There are some Android5.0 code that caused the error, in fact should be this Android plugin is not too smart bar. This will be the first. After a deeper understanding.

Attached: Appcompat_v7 effect

1.APPCOMPAT_V7: Application Compatibility Pack, V7 says version number 7, that is, android2.1. This Compatibility Pack supports the 2.1 version number above system
2. Recently, Google has officially set up a androidproject for compatible jar packages with certain resource files. is actually a resource pool. Right click on this entry to build path-click on Android and you will find the is library ticked to indicate that it is a vault. In fact, this library can be shared by multiple projects. The V7.jar package is already included in the library, and other resources are available that you can use to put some common code and resources into the library when developing multiple projects. Easy to use. The low version of ADT created the project without its own initiative to generate the library. We are able to create new projects only when we need them. You can hook the is library. The high version of ADT's own initiative to generate the library, assuming that it is not necessary, just need to right-click on your new project to the properties-Android-Library under the selected libraries, click Remove removed.


3. When your app is packaged or executed, the library will voluntarily package and compile itself as part of the project.


References: http://jingyan.baidu.com/article/3ea51489e04eb852e61bbaa4.html


After Eclipse updates the Android SDK, the new project appears appcompat_v7project related issues

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.