0
错误:错误检索的项目父:没有资源发现在给定名称匹配 'Theme.AppCompat.Light.NoActionBar'
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorAccent">@color/colorAccent</item>
<item name="android:textColorPrimary">@color/colorTextPrimary</item>
<item name="android:textColorSecondary">@color/colorTextSecondary</item>
</style>
这是styles.xml文件。下面的代码导致这个错误 - 我已经把所有必要的库和jar文件,我也尝试改变语法的一点点和许多东西,但我无法解决问题。这是非常重要的。请帮帮我。谢谢。
我试过以下内容: 您需要在Android项目中引用此AppCompat库。
将库导入Eclipse。
右键单击您的Android项目。 选择属性。 点击底部的“添加...”添加库。选择支持库 清理并重建您的项目。
它仍然不起作用。现在
编辑:
我已经安装了Android SDK中5.0(API 21),但它仍然无法正常工作。该错误的行是 在此文件(styles.xml)中安装android sdk 5.0(API 21)之前还有3个错误,但现在它们消失了。请帮我删除剩余的错误。
改变这个'家长=“@风格/ Theme.AppCompat.Light.DarkActionBar”' – Pankaj
可能的重复[找不到与名称'@ style/Theme.AppCompat.Light'匹配的资源](http://stackoverflow.com/questions/21059612/no-resource-found-that-matches-the-given- name-style-theme-appcompat-light) –
我想保留NoActionBar,但即使我把@ style /作为前缀它不起作用 –