I am trying to use Floating Action Button(FAB) in my application. However, when I am declaring the same I get the error:
android.support.design.widget.FloatingActionButton could not be instantiated.
I have added following commands to my gradle file:
compile 'com.android.support:appcompat-v7:23.1.1'
compile 'com.android.support:design:23.1.1'
compile 'com.android.support:support-v4:23.1.1'
I have also tried with adding following to my style parent:
parent="@style/Theme.AppCompat"
Also tried having my Activity class extend Activity
as well as AppCompatActivity
.
Am I missing something? Pls. help