2017-10-09 99 views
-4

當我運行應用程序在Android工作室與按F5我看到了錯誤,你可以看到這個鏈接上的錯誤![截圖錯誤] [1] 我該如何解決它?如何解決將字節碼轉換爲dex的錯誤?

搖籃:

apply plugin: 'com.android.application' 

android { 
compileSdkVersion 26 
buildToolsVersion '26.0.2' 
defaultConfig { 
    ...  
} 
... 

dependencies { 
compile fileTree(include: ['*.jar'], dir: 'libs') 

compile 'com.github.bumptech.glide:glide:3.7.0' 
compile 'com.android.volley:volley:1.0.0' 
compile 'com.android.support.constraint:constraint-layout:1.0.0-alpha7' 
compile 'ir.adad.androidsdkv3:AdadSDKv3:3.3.1' 
compile 'com.android.support:appcompat-v7:26.0.0-alpha1' 
compile 'com.android.support:recyclerview-v7:26.0.0-alpha1' 
compile 'com.android.support:design:26.0.0-alpha1' 
} 
apply plugin: 'com.google.gms.google-services' 

錯誤

Error:Execution failed for task ':app:transformClassesWithDexForDebug'. 
> com.android.build.api.transform.TransformException: 
com.android.ide.common.process.ProcessException: 
java.util.concurrent.ExecutionException: 
com.android.ide.common.process.ProcessException: Error while executing java 
process with main class com.android.dx.command.Main with arguments {--dex -- 
num-threads=4 --output 
+1

顯示您的gradle這個文件 –

回答

1

在app.gradle啓用Multidex

android { 
    defaultConfig { 
     multiDexEnabled true 
    }  
} 
+0

添加該代碼現在我看到這個錯誤後的https: //pasteboard.co/GO67SzCd.png –

+0

@MasihKolahdouzan分享你的'build.gradle' –

+0

@NileshRathod我上傳了https://ufile.io/0frow –

相關問題