java.lang.RuntimeException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • Android FTP: Cannot connect to Server
    via Stack Overflow by Lizzie
    ,
  • Downloading txt file from ftp server
    via Stack Overflow by Ihara
    ,
  • Android FTP connection problems
    via Stack Overflow by deportes
    ,
  • Send email in background
    via Stack Overflow by Reshmin
    ,
  • Android FTP file Upload
    via Stack Overflow by squietschi
    ,
  • XMPP and ANDROID
    via Stack Overflow by Hassaan Rabbani
    ,
    • java.lang.RuntimeException: Unable to start activity ComponentInfo{com.uploadtonas_03/com.uploadtonas_03.MainActivity}: android.os.NetworkOnMainThreadException at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2250) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2300) at android.app.ActivityThread.access$600(ActivityThread.java:144) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1295) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:150) at android.app.ActivityThread.main(ActivityThread.java:5162) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:525) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:744) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560) at dalvik.system.NativeStart.main(Native Method) Caused by: android.os.NetworkOnMainThreadException at android.os.StrictMode$AndroidBlockGuardPolicy.onNetwork(StrictMode.java:1133) at java.net.InetAddress.lookupHostByName(InetAddress.java:385) at java.net.InetAddress.getAllByNameImpl(InetAddress.java:236) at java.net.InetAddress.getByName(InetAddress.java:289) at org.apache.commons.net.SocketClient.connect(SocketClient.java:209) at com.uploadtonas_03.MainActivity.onCreate(MainActivity.java:24) at android.app.Activity.performCreate(Activity.java:5133) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2214)

    Users with the same issue

    Indri Yunita
    4 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Hiren Amaliyar
    5 times, last one,
    38 more bugmates