I was creating my project using android 4.4, now I want to build it with android 2.3.3.
I got some errors in my style.xml that theme not supported.
To resolve this error I have imported the Sherlock Action Bar library. Now my style.xml error is resolved but I now get an error 'R' is missing from project
I have cleaned the project but it is not resolved.
Does anyone know how can I resolve this issue ?
My log cat is
[2014-07-21 06:59:00 - PingMyAndroid] C:\Users\Bilal Khalid\android_development\PingMyAndroid\res\values\styles.xml:10: error: Error: No resource found that matches the given name: attr 'android:backgroundStacked'.
[2014-07-21 06:59:00 - PingMyAndroid] C:\Users\Bilal Khalid\android_development\PingMyAndroid\res\values\styles.xml:17: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light.DarkActionBar'.
[2014-07-21 06:59:00 - PingMyAndroid] C:\Users\Bilal Khalid\android_development\PingMyAndroid\res\values\styles.xml:18: error: Error: No resource found that matches the given name: attr 'android:actionBarStyle'.
[2014-07-21 06:59:00 - PingMyAndroid] C:\Users\Bilal Khalid\android_development\PingMyAndroid\res\values\styles.xml:20: error: Error: No resource found that matches the given name: attr 'android:alertDialogTheme'.
[2014-07-21 06:59:00 - PingMyAndroid] C:\Users\Bilal Khalid\android_development\PingMyAndroid\res\values\styles.xml:77: error: Error: No resource found that matches the given name: attr 'android:buttonBarButtonStyle'.
[2014-07-21 06:59:00 - PingMyAndroid] C:\Users\Bilal Khalid\android_development\PingMyAndroid\res\values\styles.xml:73: error: Error: No resource found that matches the given name: attr 'android:windowMinWidthMajor'.
[2014-07-21 06:59:00 - PingMyAndroid] C:\Users\Bilal Khalid\android_development\PingMyAndroid\res\values\styles.xml:74: error: Error: No resource found that matches the given name: attr 'android:windowMinWidthMinor'.
[2014-07-21 06:59:00 - PingMyAndroid] C:\Users\Bilal Khalid\android_development\PingMyAndroid\res\values-v11\styles.xml:7: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light'.
[2014-07-21 06:59:00 - PingMyAndroid] C:\Users\Bilal Khalid\android_development\PingMyAndroid\res\values-v14\styles.xml:8: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light.DarkActionBar'
.
Did you add ABS as a library to your project? The R file will not generate is there is an error in the xml from what i've experienced.
If you haven't added ABS as a library follow:
Right-click project in package explorer->Properties->Android->Under library click Add->Select ABS->Click ok-> should be good to go after that.
Related
Hi I am trying to build my old project nearly two year old and also i am using eclipse but when i add depedency to my project it shows appcombat v7 jar file missing HERE are screen shot
and in my project properties it shows appcombat..../bin appcombat v7.jar file is missing so i copied jar file from sdk and paste it after that my project which shows ! now shows error * also appcombat is showing error please help me guys here is screen shot of that
In appcombat under resource->values-v21->style_base->
<style name="Base.Widget.AppCompat.ActionButton"
parent="android:Widget.Material.ActionButton">
</style>
it shows error Error retrieving parent for item: No resource found that matches the given name 'android:Widget.Material.ActionButton'.
error log is:
[2015-09-08 11:38:37 - Raftaar_Jyotish] D:\Gaurav\Work\v7\appcompat\res\values-v21\themes_base.xml:137: error: Error: No resource found that matches the given name: attr 'android:colorControlNormal'.
[2015-09-08 11:38:37 - Raftaar_Jyotish]
[2015-09-08 11:38:37 - Raftaar_Jyotish] D:\Gaurav\Work\v7\appcompat\res\values-v21\themes_base.xml:134: error: Error: No resource found that matches the given name: attr 'android:colorPrimary'.
[2015-09-08 11:38:37 - Raftaar_Jyotish]
[2015-09-08 11:38:37 - Raftaar_Jyotish] D:\Gaurav\Work\v7\appcompat\res\values-v21\themes_base.xml:135: error: Error: No resource found that matches the given name: attr 'android:colorPrimaryDark'.
[2015-09-08 11:38:37 - Raftaar_Jyotish]
[2015-09-08 11:38:37 - Raftaar_Jyotish] D:\Gaurav\Work\v7\appcompat\res\values-v21\themes_base.xml:144: error: Error: No resource found that matches the given name: attr 'android:windowElevation'.
[2015-09-08 11:38:37 - Raftaar_Jyotish]
[2015-09-08 11:38:37 - Raftaar_Jyotish] D:\Gaurav\Work\v7\appcompat\res\values-v21\themes_base.xml:148: error: Error: No resource found that matches the given name: attr 'android:windowElevation'.
[2015-09-08 11:38:37 - Raftaar_Jyotish] ............
many times
You should import Appcompat as a project, then in properties > android set it to a library (check islibrary), and don't forget to set the appropriate project build target.
After that go to your project and from properties > android add that project as a library
I have been trying to import appcompat-v7 into my app and have had no luck at all. I need this library in order to follow the steps listed here How do I use DrawerLayout to display over the ActionBar/Toolbar and under the status bar?. I have followed the steps documented https://developer.android.com/tools/support-library/setup.html, and when I add the library to my project, I'm getting a list of errors:
.../sdk/extras/android/support/v7/appcompat/res/values-v21/themes_base.xml:136: error: Error: No resource found that matches the given name: attr 'android:colorAccent'.
.../sdk/extras/android/support/v7/appcompat/res/values-v21/themes_base.xml:140: error: Error: No resource found that matches the given name: attr 'android:colorButtonNormal'.
.../sdk/extras/android/support/v7/appcompat/res/values-v21/themes_base.xml:138: error: Error: No resource found that matches the given name: attr 'android:colorControlActivated'.
.../sdk/extras/android/support/v7/appcompat/res/values-v21/themes_base.xml:139: error: Error: No resource found that matches the given name: attr 'android:colorControlHighlight'.
.../sdk/extras/android/support/v7/appcompat/res/values-v21/themes_base.xml:137: error: Error: No resource found that matches the given name: attr 'android:colorControlNormal'.
.../sdk/extras/android/support/v7/appcompat/res/values-v21/themes_base.xml:134: error: Error: No resource found that matches the given name: attr 'android:colorPrimary'.
.../sdk/extras/android/support/v7/appcompat/res/values-v21/themes_base.xml:135: error: Error: No resource found that matches the given name: attr 'android:colorPrimaryDark'.
.../sdk/extras/android/support/v7/appcompat/res/values-v21/themes_base.xml:144: error: Error: No resource found that matches the given name: attr 'android:windowElevation'.
.../sdk/extras/android/support/v7/appcompat/res/values-v21/themes_base.xml:148: error: Error: No resource found that matches the given name: attr 'android:windowElevation'.
I have the build target to API 21 for android-support-v7-appcompat. When I clean that project, I don't receive any errors. When I add appcompat-v7 as a library to my project, that is where the errors start appearing.
I have checked my SDK manager and everything is up to date. Can anyone help steer me in the right direction where I can resolve this issue?
I am setting up Buck to speed up the build of an Android app. The app uses the Material Theme through the appcompat-v7:21.0.+ library but Buck cannot find the required resources. Any hints?
Here is the error output:
$ buck build //app/src/main:main
Using buckd.
[-] PROCESSING BUCK FILES...FINISHED 0.4s
[+] BUILDING...2.0s (3/6 JOBS)
|=> IDLE
|=> IDLE
|=> IDLE
|=> //app/src/main:main#aapt_package... 1.5s (running aapt_package[1.5s])
Log:
No Android platform target specified. Using default: Google Inc.:Google APIs:21
app/src/main/res/values/styles.xml:4: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.AppCompat.Light.DarkActionBar'.
app/src/main/res/values/styles.xml:14: error: Error: No resource found that matches the given name: attr 'actionBarSize'.
app/src/main/res/values-v21/styles.xml:4: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.AppCompat.Light.DarkActionBar'.
app/src/main/res/values/styles.xml:23: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.AppCompat.Light.DarkActionBar'.
app/src/main/res/values/styles.xml:33: error: Error: No resource found that matches the given name: attr 'actionBarSize'.
app/src/main/res/values/styles.xml:29: error: Error: No resource found that matches the given name: attr 'colorPrimary'.
app/src/main/res/values/styles.xml:38: error: Error: No resource found that matches the given name: attr 'editTextColor'.
app/src/main/res/values-v21/styles.xml:14: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.AppCompat.Light.DarkActionBar'.
app/src/main/res/values-v21/styles.xml:32: error: Error: No resource found that matches the given name: attr 'colorPrimary'.
BUILD FAILED: //app/src/main:main#aapt_package failed with exit code 1:
aapt_package
Download appcompat-aar file and use as dependency in your anroid_resource rule
https://github.com/facebookarchive/AntennaPod/blob/buck/BUCK#L133
https://github.com/facebookarchive/AntennaPod/blob/buck/BUCK#L64
I am trying to use a SlidingMenu (https://github.com/jfeinstein10/SlidingMenu/) in my app. My first issue was that the project was using MATCH_PARENT, which wouldn't compile for me. The minSDK was set to 5, and the targetSDK was 17. I tried changing the min to 8, which is when MATCH_PARENT was introduced, to no luck.
After replacing all of the MATCH_PARENT's with FILL_PARENT's, which both compile to -1, the project seemed fine. I then proceeded to make it use ABS as per the developer's instructions on his github. Whenever I reference ABS though, I get many errors such as:
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v14\abs__styles.xml:121: error: Error retrieving parent for item: No resource found that matches the given name 'android:TextAppearance.Holo.Widget.PopupMenu.Small'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v11\abs__themes.xml:4: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v11\abs__themes.xml:6: error: Error: No resource found that matches the given name: attr 'android:windowActionBar'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v14\abs__themes.xml:4: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v11\abs__themes.xml:8: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v11\abs__themes.xml:10: error: Error: No resource found that matches the given name: attr 'android:windowActionBar'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v14\abs__themes.xml:6: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v14\abs__themes.xml:8: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light.DarkActionBar'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v14\abs__themes.xml:14: error: Error: No resource found that matches the given name: attr 'android:actionBarWidgetTheme'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v14\abs__themes.xml:22: error: Error: No resource found that matches the given name: attr 'android:windowActionBar'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v14\abs__themes.xml:26: error: Error: No resource found that matches the given name: attr 'android:windowActionBar'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values\abs__themes.xml:196: error: Error: No resource found that matches the given name: attr 'android:windowActionBar'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values\abs__themes.xml:197: error: Error: No resource found that matches the given name: attr 'android:windowActionModeOverlay'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values\abs__themes.xml:198: error: Error: No resource found that matches the given name: attr 'android:windowCloseOnTouchOutside'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v14\abs__themes.xml:30: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Dialog'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values\abs__themes.xml:222: error: Error: No resource found that matches the given name: attr 'android:windowActionBar'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values\abs__themes.xml:223: error: Error: No resource found that matches the given name: attr 'android:windowActionModeOverlay'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values\abs__themes.xml:224: error: Error: No resource found that matches the given name: attr 'android:windowCloseOnTouchOutside'.
[2012-12-02 13:53:39 - LibrarySlidingMenu] C:\Users\RynoJvR\Dropbox\Android\LibraryActionBarSerlock\res\values-v14\abs__themes.xml:32: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light.Dialog'.
As far as I can tell, SlidingMenu is throwing the error because of some of the XML in ABS, meaning that R won't generate, and I can't use SlidingMenu.
Go to the properties .
click on the most recent target platform (which also has google maps for mapActivity). In this image its 4.2 Google Apis
I have followed the the guides on few sites and I cannot get it to work. I made sure they I created the project from existing source, and include as libraries in my project, checked targets, etc. I'm not sure what I'm missing.
I get the following errors:
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values\styles.xml:246: error: Error: No resource found that matches the given name: attr 'windowActionBar'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values\styles.xml:247: error: Error: No resource found that matches the given name: attr 'windowNoTitle'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:12: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:14: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock.Light'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:16: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock.Light.DarkActionBar'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:18: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock.ForceOverflow'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:20: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock.Light.ForceOverflow'.
[2012-08-29 21:46:56 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values\styles.xml:247: error: Error retrieving parent for item: No resource found that matches the given name '#style/Theme.HoloEverywhereDark.Sherlock'.
[2012-08-29 21:46:56 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values\styles.xml:253: error: Error retrieving parent for item: No resource found that matches the given name '#style/Theme.HoloEverywhereLight.Sherlock'.
Guides Followed:
Error importing HoloEverywhere
https://github.com/ChristopheVersieux/HoloEverywhere
The HoloEverywhere guide you linked to is a small bit out-of-date, the two themes are now called Holo.Theme and Holo.Theme.Light.
So change these lines in your Android manifest:
android:theme="#style/Theme.HoloEverywhereDark.Sherlock"
or
android:theme="#style/Theme.HoloEverywhereLight.Sherlock"
to
android:theme="#style/Holo.Theme"
or
android:theme="#style/Holo.Theme.Light"
Then Project->Clean and see if the errors disappear.
As you are using Sherlock theme(Not integrated Android Theme) you need to import that additional package under ProjectName/ folder
+ProjectName
src
gen
Android2.1
Sherlock.jar(Import tht .jar file under root Folder)
bin
. . .
I solved the problem by setting the android target of all the projects to the newest android version (v.17 atm)