0
這個問題讓我頭痛很多小時! 每次我添加了Apache POI 3.14 lib放到Android Studio中,我得到了同樣的錯誤:當我添加Apache POI庫時獲取「:app:mergeDebugResources FAILED」
Error:Execution failed for task ':app:mergeDebugResources'.
> -1
我不能運行我的應用程序,我試圖既乾淨且無任何succses重建項目都沒有。
這是我下載二進制分發文件(ZIP):https://poi.apache.org/download.html
,然後我打開它,並添加jar文件poi-3.14-20160307.jar
爲Android Studio中一個lib!
我想用這個庫來讀取Android中的XLS/XLSX文件。
這就是在gradle這個控制檯中顯示:
BUILD FAILED
Total time: 2.206 secs
Executing tasks: [:app:clean, :app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies, :app:assembleDebug]
Configuration on demand is an incubating feature.
Incremental java compilation is an incubating feature.
:app:clean
:app:preBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:checkDebugManifest
:app:preReleaseBuild UP-TO-DATE
:app:prepareComAndroidSupportAnimatedVectorDrawable2411Library
:app:prepareComAndroidSupportAppcompatV72411Library
:app:prepareComAndroidSupportSupportV42411Library
:app:prepareComAndroidSupportSupportVectorDrawable2411Library
:app:prepareDebugDependencies
:app:compileDebugAidl
:app:compileDebugRenderscript
:app:generateDebugBuildConfig
:app:mergeDebugShaders
:app:compileDebugShaders
:app:generateDebugAssets
:app:mergeDebugAssets
:app:generateDebugResValues UP-TO-DATE
:app:generateDebugResources
:app:mergeDebugResources FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:mergeDebugResources'.
> -1
打開gradle控制檯,請檢查錯誤。並讓我知道。 – Rahul
@Rah我已經發布了 – Muddz