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

  1. ,

    Create an empty public constructor in your code.

Solutions on the web

via Stack Overflow by Suzy
, 1 year ago
Unable to start activity ComponentInfo{com.example.suzanelsamahy.productsviewer/com.example.suzanelsamahy.productsviewer.MainActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void com.example.suzanelsamahy.productsviewer.POJO.Product.setPrice(double)' on a null object reference
via Stack Overflow by Cris dois
, 8 months ago
Unable to start activity ComponentInfo{com.example.afcosta.inesctec.pt.android/com.example.afcosta.inesctec.pt.android.Login}: java.lang.NullPointerException: Attempt to invoke virtual method 'double android.location.Location.getLatitude()' on a null object reference
via Stack Overflow by The doctor
, 4 months ago
Unable to start activity ComponentInfo{com.mohana.pdc/com.mohana.pdc.NodeList}: java.lang.NullPointerException: Attempt to invoke virtual method 'double android.location.Location.getLatitude()' on a null object reference
via GitHub by kueda
, 1 year ago
Unable to start activity ComponentInfo{org.inaturalist.android/org.inaturalist.android.ObservationViewerActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'double java.lang.Double.doubleValue()' on a null object reference
via Stack Overflow by saksham gulati
, 2 years ago
Unable to start activity ComponentInfo{saksham.geofencing/saksham.geofencing.MapsActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'double android.location.Location.getLatitude()' on a null object reference
via GitHub by derMart
, 1 year ago
Unable to start activity ComponentInfo{com.android.messaging/com.android.messaging.ui.appsettings.PerSubscriptionSettingsActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.preference.Preference.onPrepareForRemoval()' on a null object reference
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.suzanelsamahy.productsviewer/com.example.suzanelsamahy.productsviewer.MainActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void com.example.suzanelsamahy.productsviewer.POJO.Product.setPrice(double)' on a null object reference	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)