2013-06-25 55 views
3

我试图编译一个项目与目标SDK 13,然后我有关于资源的一些错误。我有几个同样的错误,其中之一是:Android工作室在编译时出错,没有找到资源

android-apt-compiler: [android-master5] C:\Documents and Settings\...\Local Settings\Application Data\Android\android-studio\sdk\android-master5\res\values\styles.xml:24: error: Error retrieving parent for item: No resource found that matches the given name 'style/Theme.Sherlock.Light.DarkActionBar'. 

我该怎么办?

对不起,英语不好。

+0

这是在32位的Linux? –

回答

0

在是在错误中提到的文件styles.xml,如果线24字面意思是:

'style/Theme.Sherlock.Light.DarkActionBar' 

然后将其更改为:

'@style/Theme.Sherlock.Light.DarkActionBar' 

(你只是错过了@符号)

+0

仍然是同样的问题,即使我输入@符号 – harisdev

+0

这很奇怪...你介意发布styles.xml文件的内容吗? –

+1

我得到同样的问题。这解决了吗? – jonney

0

我在搜索类似的错误消息时发现了这篇文章,这是从eclipse迁移到Android Studio时得到的。在我的情况非常相同的主题是找不到的AndroidManifest.xml: https://github.com/JakeWharton/ActionBarSherlock-Gradle-Sample

说到:

我的问题是通过添加

compile 'com.actionbarsherlock:actionbarsherlock:[email protected]' 
compile 'com.android.support:support-v4:18.0.+' 

在gradle这个文件的依赖关系的建议在这里解决的,似乎AppCompat是向后兼容ActionBars的新东西...

相关问题