首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >exMsg=在路径: DexPathList[[....]]上找不到类"android.support.v7.app.AppCompatDelegateImplV7“

exMsg=在路径: DexPathList[[....]]上找不到类"android.support.v7.app.AppCompatDelegateImplV7“
EN

Stack Overflow用户
提问于 2017-05-08 14:19:59
回答 1查看 296关注 0票数 1

在我的android app.When中有一个问题,我运行它工作正常,直到显示初始闪屏之后,应用程序会因为显示以下错误而终止

代码语言:javascript
复制
D/Error: ERR: exClass=java.lang.ClassNotFoundException
D/Error: ERR: exMsg=Didn't find class "android.support.v7.app.AppCompatDelegateImplV7" on path: DexPathList[[dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-universal-image-loader-1.9.3_2e43e3c9ab19d582dc42c3f097ec207646369502-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_9-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_8-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_7-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_6-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_5-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_4-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_3-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_2-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_1-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-slice_0-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-nineoldandroids-2.4.0_c7e97c88f2b4c03d5b018314d7e0360b569d2fe1-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-listviewanimations_lib-manipulation_3.1.0_3ea7d78cb8c9d162b8cf20f91d41b56d8350ede6-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-listviewanimations_lib-core_3.1.0_d5b6f2edc013f81d2d7c430ea57e27009918d720-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-listviewanimations_lib-core-slh_3.1.0_68ff82cc1f3aa9efe269eb0ef51c87fce55e43d3-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-json-simple-1.1_d6065e905baed35220996afac35ab5d2effc7d1b-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-httpmime-4.3_c806319611d02c1db14d0f99820609207c97b64f-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-httpcore-4.3_c75b97ba5d8ce326b7ae8acc4a0c67e27dd681e6-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-google-api-services-youtube-v3-rev137-1.20.0_16b6a7cef68d066c74e8cce7ff54b7c6e6d18564-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-com.mcxiaoke.volley-library-aar-1.0.0_442b26a71dcf49f1326a59f7dd93b5abcc40808f-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-com.google.android.gms-play-services-tasks-9.2.1_49e1e9f411b0d0f2c0d9750b776a6e724b71f888-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-com.google.android.gms-play-services-basement-9.2.1_16e20869c8c618f93d5db229381552d887ceb8a9-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-com.google.android.gms-play-services-base-9.2.1_be65c630d67721aa9baf669ad5365aef43eda2f6-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-com.google.android.gms-play-services-auth-base-9.2.1_7f3fe4c347fe9ee24a2b0a4f8177bcae73bdf43c-classes.dex", dex file "/data/data/thaikkudambridge.kodspider.com.thaikkudambridge/files/instant-run/dex/slice-com.google.android.gms-play-services-auth-9.2.1_c3cef
D/Error: ERR: file=BaseDexClassLoader.java
D/Error: ERR: class=dalvik.system.BaseDexClassLoader
D/Error: ERR: method=findClass line=56
D/Error: ERR: stack=java.lang.NoClassDefFoundError: Failed resolution of: 
Landroid/support/v7/app/AppCompatDelegateImplV7;

这是我的构建gradle文件代码

代码语言:javascript
复制
apply plugin: 'com.android.application'

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

compile project(':StickyListHeaders')
compile 'com.mcxiaoke.volley:library-aar:1.0.0'
compile 'com.android.support:appcompat-v7:22.1.1'   
compile group: 'com.googlecode.json-simple', name: 'json-simple', version: '1.1'
compile 'com.facebook.android:facebook-android-sdk:4.0.0'
compile 'com.google.android.gms:play-services-auth:9.2.1'
compile files('libs/YouTubeAndroidPlayerApi.jar')
compile "org.apache.httpcomponents:httpcore:4.2.4"
compile ("org.apache.httpcomponents:httpmime:4.3")
compile 'com.android.support:multidex:1.0.1'
 }

 android {
compileSdkVersion 21
buildToolsVersion "22.0.1"
packagingOptions {
    exclude 'META-INF/DEPENDENCIES.txt'
    exclude 'META-INF/LICENSE.txt'
    exclude 'META-INF/NOTICE.txt'
    exclude 'META-INF/NOTICE'
    exclude 'META-INF/LICENSE'
    exclude 'META-INF/DEPENDENCIES'
    exclude 'META-INF/notice.txt'
    exclude 'META-INF/license.txt'
    exclude 'META-INF/dependencies.txt'
    exclude 'META-INF/LGPL2.1'
    }


    defaultConfig {
    minSdkVersion 14 //lower than 14 doesn't support multidex
    targetSdkVersion 21
    // Enabling multidex support.
    multiDexEnabled true   }

  configurations {
    all*.exclude group: 'com.android.support', module: 'support-v4'
    all*.exclude group: 'com.android.support', module: 'support-annotations'
   }

compileOptions {
    sourceCompatibility JavaVersion.VERSION_1_7
    targetCompatibility JavaVersion.VERSION_1_7
}

lintOptions {
    abortOnError false
}
sourceSets {
    main {
        manifest.srcFile 'AndroidManifest.xml'
        java.srcDirs = ['src']
        resources.srcDirs = ['src']
        aidl.srcDirs = ['src']
        renderscript.srcDirs = ['src']
        res.srcDirs = ['res']
        assets.srcDirs = ['assets']
    }

    // Move the tests to tests/java, tests/res, etc...
    instrumentTest.setRoot('tests')

    // Move the build types to build-types/<type>
    // For instance, build-types/debug/java, build-types/debug/AndroidManifest.xml, ...
    // This moves them out of them default location under src/<type>/... which would
    // conflict with src/ being used by the main source set.
    // Adding new build types or product flavors should be accompanied
    // by a similar customization.
    debug.setRoot('build-types/debug')
    release.setRoot('build-types/release')
}
}

我怎么才能修复它呢?

这些是我使用的库

代码语言:javascript
复制
android-support-v4.jar
google-api-services-youtube-v3-rev137-1.20.0.jar
listviewanimations_lib-core-slh_3.1.0.jar
listviewanimations_lib-core_3.1.0.jar
listviewanimations_lib-manipulation_3.1.0.jar
nineoldandroids-2.4.0.jar
universal-image-loader-1.9.3.jar
volley-1.0.0-sources.jar
YouTubeAndroidPlayerApi.jar
EN

回答 1

Stack Overflow用户

发布于 2017-05-08 14:31:38

在android studio中禁用即时运行

文件->设置->构建、执行、部署->即时运行->取消选中第一个复选框

清理并重新生成项目,然后运行。

票数 -1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/43840984

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档