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

Solutions on the web

via GitHub by hssm
, 1 year ago
Attempt to invoke virtual method 'boolean android.preference.CheckBoxPreference.isChecked()' on a null object reference
java.lang.NullPointerException: Attempt to invoke virtual method 'boolean android.preference.CheckBoxPreference.isChecked()' on a null object reference	at com.ichi2.anki.Preferences.updatePreference(Preferences.java:470)	at com.ichi2.anki.Preferences.access$300(Preferences.java:90)	at com.ichi2.anki.Preferences$SettingsFragment.onSharedPreferenceChanged(Preferences.java:812)	at android.app.SharedPreferencesImpl$EditorImpl.notifyListeners(SharedPreferencesImpl.java:479)	at android.app.SharedPreferencesImpl$EditorImpl.apply(SharedPreferencesImpl.java:387)	at android.preference.PreferenceManager.setNoCommit(PreferenceManager.java:659)	at android.preference.PreferenceManager.inflateFromResource(PreferenceManager.java:284)	at android.preference.PreferenceFragment.addPreferencesFromResource(PreferenceFragment.java:326)	at com.ichi2.anki.Preferences.initSubscreen(Preferences.java:308)	at com.ichi2.anki.Preferences.access$100(Preferences.java:90)	at com.ichi2.anki.Preferences$SettingsFragment.onCreate(Preferences.java:788)	at android.app.Fragment.performCreate(Fragment.java:2335)	at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:949)	at android.app.BackStackRecord.setLastIn(BackStackRecord.java:857)	at android.app.BackStackRecord.calculateFragments(BackStackRecord.java:897)	at android.app.BackStackRecord.run(BackStackRecord.java:727)	at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1578)	at android.app.FragmentManagerImpl$1.run(FragmentManager.java:483)	at android.os.Handler.handleCallback(Handler.java:751)	at android.os.Handler.dispatchMessage(Handler.java:95)	at android.os.Looper.loop(Looper.java:154)	at android.app.ActivityThread.main(ActivityThread.java:6077)	at java.lang.reflect.Method.invoke(Native Method)	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:865)	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:755)