我已将Android Studio
,Gradle
和我的库更新到最新版本,现在当我尝试在三星设备上运行我的APP时,我遇到了一个错误的错误:
08-09 11:31:36.037 24120-24120/com.example E/AndroidRuntime﹕ FATAL EXCEPTION: main
Process: com.example, PID: 24120
java.lang.NoClassDefFoundError: android.support.v7.appcompat.R$layout
at android.support.v7.app.AppCompatDelegateImplV7.ensureSubDecor(AppCompatDelegateImplV7.java:324)
at android.support.v7.app.AppCompatDelegateImplV7.setContentView(AppCompatDelegateImplV7.java:246)
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:106)
at com.example.marian.digimusicstream.musicPlayer.onCreate(musicPlayer.java:95)
at android.app.Activity.performCreate(Activity.java:5458)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1093)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2376)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2470)
at android.app.ActivityThread.access$900(ActivityThread.java:174)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1307)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:146)
at android.app.ActivityThread.main(ActivityThread.java:5593)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099)
at dalvik.system.NativeStart.main(Native Method)
我尝试使用proguard文件,因为它在这里描述:Crash: java.lang.NoClassDefFoundError: android.support.v7.appcompat.R$layout但是没有结果,有没有办法解决这个问题?
我已经在LG G3和Nexus 7上成功测试了我的应用程序,在三星S4 mini和S2上测试了应用程序Crash,当它打开时。