I am trying to make a scrollable tab but when I set a view in my fragment layout the app starts giving error as Error inflating class null.It was working whenthe view is not
You need to define the proper package name for the view class. By looking at the package name defined in your class you can define it in your layout xml like this
<com.example.neelay.anotherbeatbox.Fragment.Songs
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#fff"
android:layout_marginTop="150dp"/>
Replace
<view
with
<View
View
is an actual widget you can inflate and seems to fit your intended purpose. view
is a special tag and with it you can inflate view classes by a name defined in attributes, and you have not defined such class name (it comes up as null
in inflater).