java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{ch.ethz.inf.vs.android.spurra.sensors/ch.ethz.inf.vs.android.spurra.sensors.SensorActivity}: java.lang.NullPointerException

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

,
via Stack Overflow by CommonsWare

Try loading the text file into a WebView, then printing the contents of the WebView.

,

Create an empty public constructor in your code.

Solutions on the web

via Stack Overflow by BananaCode
, 2 years ago
Unable to instantiate activity ComponentInfo{ch.ethz.inf.vs.android.spurra.sensors/ch.ethz.inf.vs.android.spurra.sensors.SensorActivity}: java.lang.NullPointerException
via Stack Overflow by Mohsen
, 2 weeks ago
Unable to instantiate activity ComponentInfo{***/com.text.NewActivity}: java.lang.NullPointerException
via Stack Overflow by Chris James Hancocks
, 2 years ago
Unable to instantiate activity ComponentInfo{com.smarte.smartipcontrol/com.smarte.smartipcontrol.IPControl}: java.lang.NullPointerException
via Stack Overflow by user2236096
, 2 years ago
Unable to instantiate activity ComponentInfo{com.hychentsa.compoundinterest_v001/com.hychentsa.compoundinterest_v001.MainActivity}: java.lang.NullPointerException
via Stack Overflow by Rahi M.
, 2 years ago
Unable to instantiate activity ComponentInfo{com.example.alarmmanager/com.example.eventmanager.AlertActivity}: java.lang.NullPointerException
via Stack Overflow by user2246076
, 2 years ago
Unable to instantiate activity ComponentInfo{com.example.real/com.example.real.MainActivity}: java.lang.NullPointerException
java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{ch.ethz.inf.vs.android.spurra.sensors/ch.ethz.inf.vs.android.spurra.sensors.SensorActivity}: java.lang.NullPointerException
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2024)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2125)
at android.app.ActivityThread.access$600(ActivityThread.java:140)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1227)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:4898)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1006)

Users with the same issue

Once, 1 month ago
33 times, 2 months ago
8 times, 2 months ago
468 times, 3 months ago
65 times, 5 months ago

Write tip

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