In grable I write compile 'com.android.support:design:22.2.0' does not load, underlines in red, also happens with all android libraries.
If you connect a non-android, for example compile 'org.adw.library:discrete-seekbar:1.0.0' everything connects perfectly.

What is the problem?

Mistake:

Dependency 'com.android.support:design:22.2.0' not found

build.gradle :

 android { compileSdkVersion 22 buildToolsVersion "22.0.1" defaultConfig { applicationId "com.mycompany.myapp18" minSdkVersion 14 targetSdkVersion 21 versionCode 1 versionName "1.0" } buildTypes { release { minifyEnabled false runProguard false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } } repositories { jcenter() } dependencies { compile 'com.android.support:design:22.2.0' //compile 'com.android.support:cardview-v7:+' compile fileTree(dir: 'libs', include: ['*.jar']) compile files ('libs/android-support-v4.jar') //compile files ('libs/android-support-design.jar') //compile project('ParallaxScroll') compile 'com.github.nirhart:parallaxscroll:1.0' //./gradlew :ParallaxScroll:assembleDebug compile 'com.melnykov:floatingactionbutton:1.3.0' compile files ('libs/android-support-v7-cardview.jar') compile files ('libs/android-support-v7-recyclerview.jar') //compile 'com.github.navasmdc:MaterialDesign:1.5@aar' compile 'me.drakeet.materialdialog:library:1.2.2' compile 'org.adw.library:discrete-seekbar:1.0.0' compile 'com.getbase:floatingactionbutton:1.10.0' } 
  • Show the whole gradle file. PS not grable, but gradle - Werder
  • Is the Google Support Repository installed? - Vladyslav Matviienko

1 answer 1

Upgrade to the latest Android Support Repository in SDK Manager

 compile files ('libs/android-support-v7-cardview.jar') compile files ('libs/android-support-v7-recyclerview.jar') compile files ('libs/android-support-v4.jar') 

This is to remove, instead:

 compile 'com.android.support:cardview-v7:21.0.0' compile 'com.android.support:recyclerview-v7:21.0.0' compile 'com.android.support:support-v4:21.0.0' 

instead of 21.0.0 substitute the appropriate version that is in you in the SDK Manager, now the current 22.2.1

  • There is one problem, due to some circumstances I am programming in AIDE on an android tablet. Therefore, the SDK Manager is not an option. - user186301
  • @ user186301 Install the application from the Google Play SDK Manager , it was created specifically for AIDE - anber
  • I installed, now when connecting <android.support.design.widget.FloatingActionButton android: id = "@ + id / fab" android: layout_width = "wrap_content" android: layout_height = "wrap_content" android: layout_margin = "16dp" /> < / LinearLayou knocks out the error android.view.InflateException: Binary XML file line # 100: Error inflating class android.support.design.widget.FloatingActionButton 07-27 22: 03: 31.057 7276 7276 E AndroidRuntime - user186301
  • @ user186301 Theme should inherit from Theme.AppCompat and Theme.AppCompat from AppCompatActivity - anber
  • So what? I have it so - user186301