My application worked fine until I tried to add a library to it. After I added the library, Android Studio gives me the following error:
Error:(26) No
Note: The versions have changed by now, so replace below versions with the most recent ones.
The accepted answer gets rid of the error in case layout_behavior is not needed, however if you actually want to use:
app:layout_behavior="@string/appbar_scrolling_view_behavior"
Make sure to add the proper dependency to the build.gradle file of your module:
apply plugin: 'com.android.library'
android {
compileSdkVersion 23
buildToolsVersion "21.1.2"
//Other stuff....
}
dependencies {
//Importing the design library fixes the build
compile 'com.android.support:design:23.1.0'
//Other libraries....
}
I.e. add this line to your dependencies:
compile 'com.android.support:design:23.1.0'