Skip to content Skip to sidebar Skip to footer

Sharedpreferences In Android Returns Null When Called From Another Activity

I made two activities, one for the widget and one for the settings activity. There are two variables 'strSavedMem1' & 'strSavedMem1' initialised in the settings activity... an

Solution 1:

You should

  • check if the commit worked and returned true.
  • open both SharedPreferences in the same way using MODE_PRIVATE (as a constant and not its value)

Post a Comment for "Sharedpreferences In Android Returns Null When Called From Another Activity"