FATAL EXCEPTION: java.lang.NoClassDefFoundError: android.support.v7.appcompat.R$layout

后端 未结 5 1184
别那么骄傲
别那么骄傲 2020-12-08 05:28

I just migrated from eclipse to studio. I followed one blog to export project from eclipse to studio. The app working fine in lollipop and throwing the following error in pr

5条回答
  •  攒了一身酷
    2020-12-08 05:54

    In the android documentation for v7 appcompat is a note:

    Note: This library depends on the v4 Support Library. If you are using Ant or Eclipse, make sure you include the v4 Support Library as part of this library's classpath.

    I think thats your problem since you have comment out the line in your gradle:

       // compile "com.android.support:support-v4:18.0.+"
    

    Add the line again and try to compile the project.

    Also i see no com.android.support:appcompat-v7:21.0.0 line in your gradle

提交回复
热议问题