I have imported android support-v7 appcompat library From File >Import >Android >Existing Android Code Into Workspace >sdk >extra >android >support >v7 >appcompat. when I click finish I get " android supprt v 7 appcompat" in project explorer, it shows me an error.
in android-support-v7-appcompat\res\values\styles_base.xml -> I get the following error:
"error: Error retrieving parent for item: No resource found that matches the given name 'android:Widget.Material.ActionButton'.
I have search this problem couldn't solve my problem.
I wanted to upload screen shoot unfortunately, I am not able to since it needs at least 10 reputation :(
any ideas please
It sounds as though you are not compiling with the Android 5.0 (API level 21) SDK.
You need to install API 21 via the SDK manager, then update your project settings to compile with API 21.
Related
I have update SDK using SDK manger,after updating SDK "google-play-services_lib" not getting complied,Its showing following error.
**extras\google\google_play_services\libproject\google-play-services_lib\res\values-v11\appinvite_styles.xml:5: error: Error retrieving parent for item: No resource found that matches the given name '#android:style/Theme.Holo.Light.DialogWhenLarge.NoActionBar'.
extras\google\google_play_services\libproject\google-play-services_lib\res\values-v21\appinvite_styles.xml:5: error: Error retrieving parent for item: No resource found that matches the given name '#android:style/Theme.Material.Light.DialogWhenLarge.NoActionBar'.
extras\google\google_play_services\libproject\google-play-services_lib\res\values-v11\appinvite_styles.xml:5: error: Error retrieving parent for item: No resource found that matches the given name '#android:style/Theme.Holo.Light.DialogWhenLarge.NoActionBar'.
extras\google\google_play_services\libproject\google-play-services_lib\res\values-v21\appinvite_styles.xml:5: error: Error retrieving parent for item: No resource found that matches the given name '#android:style/Theme.Material.Light.DialogWhenLarge.NoActionBar'.**
Any Help appreciated.
Following is xml(under "values-v11") which is giving error,
<?xml version="1.0" encoding="utf-8"?>
<!-- Base preview application theme. -->
<style name="Theme.AppInvite.Preview.Base" parent="#android:style/Theme.Holo.Light.DialogWhenLarge.NoActionBar"/>
This may fix your problem
Right side click on your project select Properties -> Select Android
Under Project Build Target, check *Android 6.0 or to the latest API.
Build
One important thing : While importing library projects always copy to your workspace.
UPDATED:
Reason : Most of time google play service lib access resources from lastest API available. that's why you need to target to the latest.
This is the solution it worked for me (after a few hours):
1) Unistall the Google Play Services Lib from "Android SDK Manager". It will ask you if you want to delete also the directory in your workspace. Answer "Yes"
2) Download again the Google Play Library from the "Android SDK Manager" and follow the steps to import it to your workspace
3) Set Android Target for google-play-services-lib for 5.0.1 (these are the versions for me worked)
4) In the project you want to import, right click->properties->Android . Add again the google-play-services-lib library.
5) Set Android Target for your project to 5.0.1 (the same case that point 3: I guess it can work for other versions)
6) Only in case the above solution will not work, copy the android-support-v4.jar from <...>/sdk/extras/android/support/v4 to the "libs" folder of your project.
I hope it works for you
For the new Google Play Services, you need change the project target in the project.properties file (The Google Play Services Lib project, not your project):
In the below file:
google-play-services_lib/project.properties
Change the below line
target=**android-9*
to:
target=**android-23**
Tried to compile your project with the android target-sdk-version="21".
It worked for me.
I fixed it by changing the minSdkVersion in google-play-services_lib manifest to the minimum SDK version used by my app. Example: <uses-sdk android:minSdkVersion="14"/>
i'm new in android development . i installed Eclipse and JDK and Installed( API 20) and (API 8) and all the extras but when i opened eclipse for android project i got error in Appcompat_v7(res->values_v23->styles_base.xml->(
) .
Error is :enter image description here
Error retrieving parent for item: No resource found that matches the given name 'android:Widget.Material.Button.Colored'. styles_base.xml /appcompat_v7/res/values-v23
Change the Compile Sdk to 23. That Solve my Problem.
Update
As the OP has now Android Studio,
here are a few links to tackle the same,,
Boost up Gradle build time - 1
Boost up Gradle build time - 2
basically you need to add org.gradle.daemon=true to build.gradle file.
you can search for similar, and will find many threads on SO for the same,
Note: Its not "Guaranteed" to work but why not give a try
I would suggest you to use Android Studio instead of Eclipse.
Now the error, you will have to update your SDK platform to API 23 which is the Latest API(as of now), as it will require that particular version for compiling. Your current is API 20 which will not include the styles which is required by appcompat_v7.
i programed with eclipse but i try make project today that eclipse make errors.
solution that told all is for android studio.
enter image description here
You should change your target sdk version to 23.
Reason : you may be using support design library (v23.z.z) which is dependent on the sdk version 23
I have updated my all sdk and api version , .... to the last version. but now i have an error in my appcompat_v7. I also reimported the appcompat_v7 project from android sdk support library folder. But it didn't work. my min sdk version is api7 in the project and target sdk is api22 (android 5.1.1). I get this error:error: Error retrieving parent for item: No resource found that matches the given name 'android:Widget.Material.ActionButton'.
How can i solve it?
Thank you for your advice.
(sorry for my bad English!)
I am using ActionBarSherlock to implement action bar on my Android 2.1 API 7 project. (With Eclipse IDE)
In order to use sherlock, I imported sherlock library as a existing project on Eclipse. Then, I added it as library on my own project.
However, in my own project, the Eclipse's console shows me the following error:
JakeWharton-ActionBarSherlock-436230d/library/res/values-v11/abs__styles.xml:4: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo'.
JakeWharton-ActionBarSherlock-436230d/library/res/values-v11/abs__styles.xml:48: error: Error: No resource found that matches the given name: attr 'android:actionBarSize'.
JakeWharton-ActionBarSherlock-436230d/library/res/values-v11/abs__styles.xml:49: error: Error: No resource found that matches the given name: attr 'android:actionBarStyle'.
...
Why??
(I have set target SDK to Android 3.2 for Sherlock.)
Set target SDK to Android 3.2(Version 14) or above. Your desired version can be anything from Android 1.5 (version 7?) upward if I remember correctly.
Afaik you have to use the api level 14 (or at least honeycomb) library when using ActionBarSherlock. You can still set the minimum version to 7, but the target version has to be ICS (or maybe honeycomb).
But then you have to make sure that you're not using any methods introduced in later versions.
Open the ABS Properties and the change the Project Build Target in the Android tab to 13.
Set in Android-manifest file to target sdk to 14