getSharedPreferences is defined in Context. Service is a Context also. On Jul 9, 9:08 am, Jeruliu <jeru....@gmail.com> wrote: > Dear all, > > I need to access the shared preference in a background service instead > of activity on phone boot up. > > But getSharedPreferences function is define in the activity, so how > can i access the data without creating the activity? > > Thanks.
-- 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en