[android-developers] nullpointer on getPreferenceManager() in sdk 13 and up
I'm trying to implement a fragemented preferences activity.
This is only the first part of my activity where it already fails:
public class PreferencesICSActivity extends PreferenceActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
PreferenceManager preferenceManager =
PreferencesICSActivity.this.getPreferenceManager();
preferenceManager.setSharedPreferencesName(Constants.Preferences.PREFERENCES_NAME);
}
...
}
I used to do the same in sdk version 7, there it worked. Now however
the getPreferenceManager() is null...
What am I doing wrong?
Kr,
Dirk Vranckaert
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home