java.lang.NoClassDefFoundError: android.support.v7.appcompat.R$styleable error -


hi have problem importing support.v7.appcompat. imported android.support.v7.app.appcompatactivity libs folder, when start running log:

11-01 17:35:42.669: e/androidruntime(1873): fatal exception: main 11-01 17:35:42.669: e/androidruntime(1873): java.lang.noclassdeffounderror: android.support.v7.appcompat.r$styleable 11-01 17:35:42.669: e/androidruntime(1873):     @ android.support.v7.app.appcompatdelegateimplbase.oncreate(appcompatdelegateimplbase.java:109) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.support.v7.app.appcompatdelegateimplv7.oncreate(appcompatdelegateimplv7.java:146) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.support.v7.app.appcompatactivity.oncreate(appcompatactivity.java:59) 11-01 17:35:42.669: e/androidruntime(1873):     @ morisson.notowaniagieldowe.mainactivity.oncreate(mainactivity.java:17) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.app.activity.performcreate(activity.java:5104) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.app.instrumentation.callactivityoncreate(instrumentation.java:1080) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.app.activitythread.performlaunchactivity(activitythread.java:2144) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.app.activitythread.handlelaunchactivity(activitythread.java:2230) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.app.activitythread.access$600(activitythread.java:141) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.app.activitythread$h.handlemessage(activitythread.java:1234) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.os.handler.dispatchmessage(handler.java:99) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.os.looper.loop(looper.java:137) 11-01 17:35:42.669: e/androidruntime(1873):     @ android.app.activitythread.main(activitythread.java:5041) 11-01 17:35:42.669: e/androidruntime(1873):     @ java.lang.reflect.method.invokenative(native method) 11-01 17:35:42.669: e/androidruntime(1873):     @ java.lang.reflect.method.invoke(method.java:511) 11-01 17:35:42.669: e/androidruntime(1873):     @ com.android.internal.os.zygoteinit$methodandargscaller.run(zygoteinit.java:793) 11-01 17:35:42.669: e/androidruntime(1873):     @ com.android.internal.os.zygoteinit.main(zygoteinit.java:560) 11-01 17:35:42.669: e/androidruntime(1873):     @ dalvik.system.nativestart.main(native method) 

and here mainactivity:

import android.os.bundle; import android.support.design.widget.tablayout; import android.support.v4.view.viewpager; import android.support.v7.app.alertdialog; import android.support.v7.app.appcompatactivity;   public class mainactivity extends appcompatactivity {         @override     protected void oncreate(bundle savedinstancestate) {         super.oncreate(savedinstancestate);         setcontentview(r.layout.main_activity);          alertdialog.builder alertdialogbuilder = new alertdialog.builder(mainactivity.this);            // viewpager , set it's pageradapter can display items         viewpager viewpager = (viewpager) findviewbyid(r.id.viewpager);         viewpager.setadapter(new samplefragmentpageradapter(getsupportfragmentmanager(),              mainactivity.this));          // give tablayout viewpager         tablayout tablayout = (tablayout) findviewbyid(r.id.sliding_tabs);         tablayout.setupwithviewpager(viewpager);      }  } 

i have seen solution problem in other posts not work case. suggestions?

if using android studio put line inside build.gradle file

    dependencies {     compile "com.android.support:appcompat-v7:21.0.+" } 

Comments

Popular posts from this blog

javascript - Slick Slider width recalculation -

jsf - PrimeFaces Datatable - What is f:facet actually doing? -

angular2 services - Angular 2 RC 4 Http post not firing -