Próbowałem dodać RecyclerView i CardView do mojego projektuRecyclerView ClassNotFound
dependencies {
compile 'com.android.support:appcompat-v7:21.0.0'
compile 'com.android.support:support-v13:21.0.0'
compile 'com.android.support:cardview-v7:21.0.0'
compile 'com.android.support:recyclerview-v7:21.0.0'
compile 'com.viewpagerindicator:library:[email protected]'
compile project(':facebook')
}
kompiluje, ale mam poniżej wyjątkiem gdy go uruchomić na urządzeniu
Caused by: java.lang.ClassNotFoundException: Didn't find class "android.view.RecyclerView" on path: DexPathList[[zip file "/data/app/xxxx.apk"],nativeLibraryDirectories=[/data/app-lib/xxxx, /vendor/lib, /system/lib]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
at java.lang.ClassLoader.loadClass(ClassLoader.java:497)
at java.lang.ClassLoader.loadClass(ClassLoader.java:457)
at android.view.LayoutInflater.createView(LayoutInflater.java:559)
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:652)
Tak, wygląda na to, że używam najnowszego buildtools i mam android.view.RecyclerView, więc nie ma błędów w Android studio, ale używam go na urządzeniu 4.4.4 ... –
W moim układzie, Napisałem to samo, wciąż stojąc przed tym samym problemem. W klasie CS mogę znaleźć android.support.v7.widget, ale nie android.support.v7.widget.RecyclerView –