简体   繁体   English

导入Cordova项目后,Android Studio aapt.exe缺少错误消息

[英]Android Studio aapt.exe missing error message after importing cordova project

Error:Execution failed for task ':CordovaLib:processDebugResources'. 错误:任务':CordovaLib:processDebugResources'的执行失败。

aapt is missing on 'C:\\Users\\rv498\\AppData\\Local\\Android\\Sdk\\build-tools\\25.0.2\\aapt.exe' C:\\ Users \\ rv498 \\ AppData \\ Local \\ Android \\ Sdk \\ build-tools \\ 25.0.2 \\ aapt.exe上缺少aapt

Hello, I have done importing cordova project to Android Studio before with no problems. 您好,我之前已经完成了将cordova项目导入Android Studio的工作,没有任何问题。 My android studio is the latest stable version because I reinstalled it today (3/17/17). 我的android studio是最新的稳定版本,因为我今天(3/17/17)重新安装了它。 Please help thanks. 请帮忙谢谢。

BTW, the reason I started to import to Android Studio from Cordova is because I was starting get message about gradle wrapper missing from cordova CLI. 顺便说一句,我开始从Cordova导入Android Studio的原因是因为我开始收到有关cordova CLI中缺少gradle包装器的消息。 I suspect this is SDK Manager issue and I went there but after few attempts, nothing really progressed. 我怀疑这是SDK Manager的问题,我去了那里,但经过几次尝试,却没有任何进展。

-I had same issue so i opened C:\\Users\\Sheriff\\AppData\\Local\\Android\\sdk\\build-tools\\24.0.2 -i saw aapt2.exe then i changed it to aapt.exe -我遇到了同样的问题,所以我打开了C:\\ Users \\ Sheriff \\ AppData \\ Local \\ Android \\ sdk \\ build-tools \\ 24.0.2-我看到了aapt2.exe,然后将其更改为aapt.exe

-Closed my project on the android studio then opened it back it was working perfectly. -关闭我在android studio上的项目,然后将其重新打开,它运行正常。

Quick solution 快速解决方案

  • check if aapt.exe is in fact missing C:\\Users\\rv498\\AppData\\Local\\Android\\Sdk\\build-tools\\25.0.2\\ 检查aapt.exe实际上是否缺少C:\\Users\\rv498\\AppData\\Local\\Android\\Sdk\\build-tools\\25.0.2\\
  • it's there? 在那? echeck perms, check %PATH% e检查权限,检查%PATH%
  • it is not there? 它不在那里吗? find where it is. 找到它在哪里。 Copy it to the location above 复制到上面的位置

of check why it looks for it in that place. 检查为什么它在那个地方寻找它。 Is there's any config file that got the above path? 是否有任何配置文件具有上述路径? If so, edit it. 如果是这样,请对其进行编辑。

aapt.exe file moved to the latest sdk build tools folder aapt.exe文件移至最新的sdk构建工具文件夹

I just found aapt.exe file in my latest Android-SDK folder ( Android_SDK\\build-tools\\28.0.3 ) 我刚刚在最新的Android-SDK文件夹中找到aapt.exe文件( Android_SDK \\ build-tools \\ 28.0.3

You can check your latest sdk build-tools folder 您可以检查最新的sdk构建工具文件夹
or 要么
You can search on total Android SDK folder by file name 您可以按文件名搜索整个Android SDK文件夹

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM