java.lang.IllegalStateException: ScrollView can host only one direct child

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

Do you know how to solve this issue? Write a tip to help other users and build your expert profile.

Solutions on the web

via Stack Overflow by Vivek Mishra
, 1 year ago
via Stack Overflow by Ashish Patel
, 8 months ago
ScrollView can host only one direct child
via Stack Overflow by Fcps
, 2 years ago
ScrollView can host only one direct child
via Stack Overflow by Karan
, 1 year ago
ScrollView can host only one direct child
via Stack Overflow by tyczj
, 2 years ago
ScrollView can host only one direct child
via Stack Overflow by ilansas
, 2 years ago
java.lang.IllegalStateException: ScrollView can host only one direct child
at android.widget.ScrollView.addView(ScrollView.java:253)
at android.support.design.widget.Snackbar.showView(Snackbar.java:475)
at android.support.design.widget.Snackbar$1.handleMessage(Snackbar.java:162)
at android.os.Handler.dispatchMessage(Handler.java:107)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:6102)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1028)

Users with the same issue

Once, 5 months ago
2 times, 5 months ago
3 times, 9 months ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Once, 1 year ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.