java.lang.RuntimeException

Unable to start activity ComponentInfo{com.assignmentexpert/com.assignmentexpert.NewMessageActivity}: java.lang.IllegalStateException: HorizontalScrollView can host only one direct child

Solutions on the web38783

  • Unable to start activity ComponentInfo{com.assignmentexpert/com.assignmentexpert.NewMessageActivity}: java.lang.IllegalStateException: HorizontalScrollView can host only one direct child
  • Unable to start activity ComponentInfo{com.test.kemo.restaurant/com.test.kemo.restaurant.MainActivity}: java.lang.IllegalStateException: HorizontalScrollView can host only one direct child
  • via GitHub by mobitar
    , 5 months ago
    Unable to start activity ComponentInfo{org.standardnotes.notes.buildfortest/org.standardnotes.notes.NoteActivity}: java.lang.IllegalStateException: HorizontalScrollView can host only one direct child
  • Stack trace

    • java.lang.RuntimeException: Unable to start activity ComponentInfo{com.assignmentexpert/com.assignmentexpert.NewMessageActivity}: java.lang.IllegalStateException: HorizontalScrollView can host only one direct child at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1651) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1667) at android.app.ActivityThread.access$1500(ActivityThread.java:117) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:935) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:123) at android.app.ActivityThread.main(ActivityThread.java:3687) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:507) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:867) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:625) at dalvik.system.NativeStart.main(Native Method) Caused by: java.lang.IllegalStateException: HorizontalScrollView can host only one direct child at android.widget.HorizontalScrollView.addView(HorizontalScrollView.java:223) at com.assignmentexpert.NewMessageActivity.addFiles(NewMessageActivity.java:165) at com.assignmentexpert.NewMessageActivity.onCreate(NewMessageActivity.java:90) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1615)

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    5 times, 1 year ago