我试图重建一个APK使用apktool但接收与在styles.xml检索父错误。我发现在网上很多帖子与此相关的建议使用旧版本apktool或aapt.exe。但我发现这个>>
http://$c$c.google.com/p/android-apktool/wiki/CommonErrors#Error_retrieving_parent_for_item:_No_resource_found_that_matches
能否请你告诉我如何使用它?
这是包含错误的行
styles.xml:61:错误:错误检索父的项目:无资源的发现,给定的名称'Widget.AppCompat.Base'匹配
。styles.xml:101:错误:错误检索父的项目:无资源的发现,给定的名称'Widget.AppCompat.Base'匹配
。styles.xml:149:错误:错误检索父的项目:无资源的发现,给定的名称'Widget.AppCompat.Base'匹配
。styles.xml:192:错误:错误检索父的项目:无资源的发现,给定的名称'Widget.AppCompat.Base'匹配
。styles.xml:208:错误:项目出错检索父:没有资源的发现,给定的名称'Widget.AppCompat.Base.DropDownItem'匹配
。styles.xml:234:错误:错误检索父的项目:无资源的发现,给定的名称'Widget.AppCompat.Base'匹配
。styles.xml:241:错误:错误检索父的项目:无资源的发现,给定的名称'Widget.AppCompat.Light.Base'匹配
。styles.xml:260:错误:错误检索父的项目:无资源的发现,给定的名称'TextAppearance.AppCompat.Base'匹配
。styles.xml:293:错误:错误检索父的项目:无资源的发现,给定的名称'Widget.AppCompat.Base'匹配
。styles.xml:485:错误:错误检索父的项目:无资源的发现,给定的名称'Theme.AppCompat.Base'匹配
和style.xml文件(这是在res>值的文件夹),其中包括这10个错误,在这里>>的 http://www.datafilehost.com/d/b22b2575
styles.xml:52:错误:错误检索父的项目:无资源的发现,给定的名称'Widget.AppCompat.Base'匹配
。这^^错误是在这里(文件夹RES>值-V14)
<样式名称=Widget.AppCompat.Base.ActivityChooserView> <项目名称=安卓重力>中心< /项目> <项目名称=机器人:背景> @绘制/ abc_ab_share_pack_holo_dark< /项目> <项目名称=?机器人:分> dividerVertical< /项目> <项目名称=机器人:showDividers>中< /项目> <项目名称=机器人:dividerPadding> 6.0dip< /项目>< /风格>
请不要介意在具有发帖codeS这里的问题上面code..i'm的空间。
解决方案正如你上面提到的第一个链接,你只需要添加一行。 http://$c$c.google.com/p/android-apktool/wiki/CommonErrors#Error_retrieving_parent_for_item:_No_resource_found_that_matches
<样式名称=Widget.AppCompat.Base>< /风格> //添加此行<样式名称=Widget.AppCompat.Base.ActivityChooserView> <项目名称=安卓重力>中心< /项目> <项目名称=机器人:背景> @绘制/ abc_ab_share_pack_holo_dark< /项目> <项目名称=?机器人:分> dividerVertical< /项目> <项目名称=机器人:showDividers>中< /项目> <项目名称=机器人:dividerPadding> 6.0dip< /项目>< /风格>
![Apktool中文版 Apktool APK反编译工具 V3.0免费版下载V3.0](https://p.xsw88.cn/allimgs/daicuo/20230906/1779.png)
每一次你满足这个问题的时候,你只需要在错误行之前添加父项目
i'm trying to rebuild an apk using apktool but receiving the Error related to retrieving parent in styles.xml. I found many posts in internet related to this suggesting to use old version apktool or aapt.exe. But i found this>>
http://code.google.com/p/android-apktool/wiki/CommonErrors#Error_retrieving_parent_for_item:_No_resource_found_that_matches
Can you please show me how to use it?
These are the lines which contains errors
styles.xml:61: error: Error retrieving parent for item: No resource found that matches the given name 'Widget.AppCompat.Base'.
styles.xml:101: error: Error retrieving parent for item: No resource found that matches the given name 'Widget.AppCompat.Base'.
styles.xml:149: error: Error retrieving parent for item: No resource found that matches the given name 'Widget.AppCompat.Base'.
styles.xml:192: error: Error retrieving parent for item: No resource found that matches the given name 'Widget.AppCompat.Base'.
styles.xml:208: error: Error retrieving parent for item: No resource found that matches the given name 'Widget.AppCompat.Base.DropDownItem'.
styles.xml:234: error: Error retrieving parent for item: No resource found that matches the given name 'Widget.AppCompat.Base'.
styles.xml:241: error: Error retrieving parent for item: No resource found that matches the given name 'Widget.AppCompat.Light.Base'.
styles.xml:260: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Base'.
styles.xml:293: error: Error retrieving parent for item: No resource found that matches the given name 'Widget.AppCompat.Base'.
styles.xml:485: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.AppCompat.Base'.
and the style.xml file(it's in the res>values folder) which contains these 10 errors is here>> http://www.datafilehost.com/d/b22b2575
styles.xml:52: error: Error retrieving parent for item: No resource found that matches the given name 'Widget.AppCompat.Base'.
and this ^^ error is here(folder res>values-v14)
<style name="Widget.AppCompat.Base.ActivityChooserView">
<item name="android:gravity">center</item>
<item name="android:background">@drawable/abc_ab_share_pack_holo_dark</item>
<item name="android:divider">?dividerVertical</item>
<item name="android:showDividers">middle</item>
<item name="android:dividerPadding">6.0dip</item>
</style>
please don't mind the spaces in the above code..i'm having problems with posting codes here.
解决方案As the first link you mentioned above , you just need add a line . http://code.google.com/p/android-apktool/wiki/CommonErrors#Error_retrieving_parent_for_item:_No_resource_found_that_matches
<style name="Widget.AppCompat.Base"></style> //add this line
<style name="Widget.AppCompat.Base.ActivityChooserView">
<item name="android:gravity">center</item>
<item name="android:background">@drawable/abc_ab_share_pack_holo_dark</item>
<item name="android:divider">?dividerVertical</item>
<item name="android:showDividers">middle</item>
<item name="android:dividerPadding">6.0dip</item>
</style>
every time you meet this problem, you just need add the parent item before the error line
相关推荐
最新文章