Android appcompat_v7 Error retrieving parent for item: No resource found that matches the given name


Are you working with the latest Android SDK with appcompat_v7 library and you have a project that has minSdkVersion below 11?, then you may get the following errors in your workspace.

Solution :

Make sure that your Manifest.xml file has the use-sdk with targetSdkVersion to the latest available,

<uses-sdk android:minSdkVersion="8" android:targetSdkVersion="20" />

Also make sure that project.properties file has target=android-20

Now just Clean + Build your project and hopefully there should be no errors!

What if i do not want to use appcompat_v7 ?

You have appcompat_v7 in your workspace because you have set the Target SDK version below 15, as Action Bar support was added in API level 11, so to support ActionBar to API levels below 11 appcompat_v7 libraries is added.

If you do not want appcompat_v7, simple work with API level 11 or above.

If you want to work on API levels below 11 see that you change,

public class MainActivity extends ActionBarActivity

to public class MainActivity extends Activity

✏️ Note : You also need to make sure that appropriate changes are made to style/theme elements in AndroidManifest.xml

Console Error Logs

/appcompat_v7/res/values-v14/styles_base.xml:24: error: Error retrieving parent for item: No resource found that matches the given name 'android:Widget.Holo.ActionBar'.
android:Widget.Holo.Light.ActionBar'.
android:Widget.Holo.ActionBar.Solid'.
android:Widget.Holo.Light.ActionBar.Solid'.
android:Widget.Holo.Light.ActionBar.Solid.Inverse'.
android:Widget.Holo.ActionButton'.
android:Widget.Holo.Light.ActionButton'.
android:Widget.Holo.ActionButton.CloseMode'.
android:Widget.Holo.Light.ActionButton.CloseMode'.
android:Widget.Holo.ActionButton.Overflow'.
android:Widget.Holo.Light.ActionButton.Overflow'.
android:Widget.Holo.ActionBar.TabBar'.
android:Widget.Holo.Light.ActionBar.TabBar'.
android:Widget.Holo.Light.ActionBar.TabBar.Inverse'.
android:Widget.Holo.ActionBar.TabView'.
android:Widget.Holo.Light.ActionBar.TabView'.
android:Widget.Holo.Light.ActionBar.TabView.Inverse'.
android:Widget.Holo.ActionBar.TabText'.
android:Widget.Holo.Light.ActionBar.TabText'.
android:Widget.Holo.Light.ActionBar.TabText.Inverse'.
android:Widget.Holo.Light.ActionMode.Inverse'.
android:TextAppearance.Holo.Widget.ActionMode.Title'.
android:TextAppearance.Holo.Widget.ActionMode.Subtitle'.
android:TextAppearance.Holo.Widget.ActionMode.Title.Inverse'.
android:TextAppearance.Holo.Widget.ActionMode.Subtitle.Inverse'.
android:TextAppearance.Holo.Widget.ActionBar.Menu'.
android:TextAppearance.Holo.Widget.ActionBar.Title'.
android:TextAppearance.Holo.Widget.ActionBar.Subtitle'.
android:TextAppearance.Holo.Widget.ActionBar.Title.Inverse'.
android:TextAppearance.Holo.Widget.ActionBar.Subtitle.Inverse'.
android:Widget.Holo.ProgressBar.Horizontal'.
android:Widget.Holo.ProgressBar'.
android:Widget.Holo.Spinner'.
android:Widget.Holo.Light.Spinner'.
android:Widget.Holo.DropDownItem.Spinner'.
android:Widget.Holo.Light.DropDownItem.Spinner'.
android:Widget.Holo.ListView.DropDown'.
android:Widget.Holo.ListView.DropDown'.
android:Widget.Holo.ListPopupWindow'.
android:Widget.Holo.Light.ListPopupWindow'.
android:Widget.Holo.PopupMenu'.
android:Widget.Holo.Light.PopupMenu'.
android:TextAppearance.Holo.Widget.PopupMenu.Large'.
android:TextAppearance.Holo.Widget.PopupMenu.Small'.
android:TextAppearance.Holo.Widget.PopupMenu.Large'.
android:TextAppearance.Holo.Widget.PopupMenu.Small'.
@android:TextAppearance.Holo.SearchResult.Title'.
@android:TextAppearance.Holo.SearchResult.Subtitle'.
@android:TextAppearance.Holo.SearchResult.Title'.
@android:TextAppearance.Holo.SearchResult.Subtitle'.
android:Widget.Holo.ActionBar'.
android:Widget.Holo.Light.ActionBar'.
android:Widget.Holo.ActionBar.Solid'.
android:Widget.Holo.Light.ActionBar.Solid'.
android:Widget.Holo.Light.ActionBar.Solid.Inverse'.
android:Widget.Holo.ActionButton'.
android:Widget.Holo.Light.ActionButton'.
android:Widget.Holo.ActionButton.CloseMode'.
android:Widget.Holo.Light.ActionButton.CloseMode'.
android:Widget.Holo.ActionButton.Overflow'.
android:Widget.Holo.Light.ActionButton.Overflow'.
android:Widget.Holo.ActionBar.TabBar'.
android:Widget.Holo.Light.ActionBar.TabBar'.
android:Widget.Holo.Light.ActionBar.TabBar.Inverse'.
android:Widget.Holo.ActionBar.TabView'.
android:Widget.Holo.Light.ActionBar.TabView'.
android:Widget.Holo.Light.ActionBar.TabView.Inverse'.
android:Widget.Holo.ActionBar.TabText'.
android:Widget.Holo.Light.ActionBar.TabText'.
android:Widget.Holo.Light.ActionBar.TabText.Inverse'.
android:Widget.Holo.Light.ActionMode.Inverse'.
android:TextAppearance.Holo.Widget.ActionMode.Title'.
android:TextAppearance.Holo.Widget.ActionMode.Subtitle'.
android:TextAppearance.Holo.Widget.ActionMode.Title.Inverse'.
android:TextAppearance.Holo.Widget.ActionMode.Subtitle.Inverse'.'android:TextAppearance.Holo.Widget.ActionBar.Menu'.
android:TextAppearance.Holo.Widget.ActionBar.Title'.
android:TextAppearance.Holo.Widget.ActionBar.Subtitle'.
android:TextAppearance.Holo.Widget.ActionBar.Title.Inverse'.
android:TextAppearance.Holo.Widget.ActionBar.Subtitle.Inverse'.
android:Widget.Holo.ProgressBar.Horizontal'.
android:Widget.Holo.ProgressBar'.
android:Widget.Holo.Spinner'.
android:Widget.Holo.Light.Spinner'.
android:Widget.Holo.DropDownItem.Spinner'.
android:Widget.Holo.Light.DropDownItem.Spinner'.
android:Widget.Holo.ListView.DropDown'.
android:Widget.Holo.ListView.DropDown'.
android:Widget.Holo.ListPopupWindow'.
android:Widget.Holo.Light.ListPopupWindow'.
android:Widget.Holo.PopupMenu'.
android:Widget.Holo.Light.PopupMenu'.
android:TextAppearance.Holo.Widget.PopupMenu.Large'.
android:TextAppearance.Holo.Widget.PopupMenu.Small'.
android:TextAppearance.Holo.Widget.PopupMenu.Large'.
android:TextAppearance.Holo.Widget.PopupMenu.Small'.
@android:TextAppearance.Holo.SearchResult.Title'.
@android:TextAppearance.Holo.SearchResult.Subtitle'.
@android:TextAppearance.Holo.SearchResult.Title'.
@android:TextAppearance.Holo.SearchResult.Subtitle'.
@android:Widget.Holo.AutoCompleteTextView'.
/appcompact_v7/res/values-v11/styles_base.xml:40: error: Error retrieving parent for item: No resource found that matches the given name 'android:Widget.Holo.Light.AutoCompleteTextView'.
/appcompact_v7/res/values-v14/styles_base.xml:225: error: Error: No resource found that matches the given name: attr 'android:dividerPadding'.
/appcompact_v7/res/values-v14/styles_base.xml:224: error: Error: No resource found that matches the given name: attr 'android:showDividers'.
/appcompact_v7/res/values-v11/themes_base.xml:31: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo'.
/appcompact_v7/res/values-v11/themes_base.xml:33: error: Error: No resource found that matches the given name: attr 'android:windowActionBar'.
/appcompact_v7/res/values-v11/themes_base.xml:40: error: Error: No resource found that matches the given name: attr 'android:windowActionModeOverlay'.
/appcompact_v7/res/values-v11/themes_base.xml:49: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light'.
/appcompact_v7/res/values-v11/themes_base.xml:51: error: Error: No resource found that matches the given name: attr 'android:windowActionBar'.
/appcompact_v7/res/values-v11/themes_base.xml:58: error: Error: No resource found that matches the given name: attr 'android:windowActionModeOverlay'.
/appcompact_v7/res/values-v14/themes_base.xml:31: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo'.
/appcompact_v7/res/values-v14/themes_base.xml:41: error: Error: No resource found that matches the given name: attr 'android:actionBarWidgetTheme'.
/appcompact_v7/res/values-v14/themes_base.xml:57: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light'.
/appcompact_v7/res/values-v14/themes_base.xml:67: error: Error: No resource found that matches the given name: attr 'android:actionBarWidgetTheme'.
/appcompact_v7/res/values-v14/themes_base.xml:83: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light.DarkActionBar'.
/appcompact_v7/res/values-v14/themes_base.xml:94: error: Error: No resource found that matches the given name: attr 'android:actionBarWidgetTheme'.
/appcompact_v7/res/values-v11/themes_base.xml:66: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Dialog'.
/appcompact_v7/res/values-v11/themes_base.xml:79: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light.Dialog'.
/appcompact_v7/res/values-v14/themes_base.xml:122: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.DialogWhenLarge'.
/appcompact_v7/res/values-v14/themes_base.xml:133: error: Error: No resource found that matches the given name: attr 'android:actionBarWidgetTheme'.
/appcompact_v7/res/values-v14/themes_base.xml:148: error: Error retrieving parent for item: No resource found that matches the given name 'android:Theme.Holo.Light.DialogWhenLarge'.
/appcompact_v7/res/values-v14/themes_base.xml:159: error: Error: No resource found that matches the given name: attr 'android:actionBarWidgetTheme'.
Copyright © Code2care 2024 | Privacy Policy | About Us | Contact Us | Sitemap