[android-developers] Shared Preferences file size

2016-07-29 Thread praveen singh
How can we calculate total size of preferences file size in a app? Is there any size limit for Shared preferences file in android? -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To unsubscribe from this group and stop receiving emails

[android-developers] Shared Preferences

2012-10-11 Thread Mario Bat
Hi, what is the difference betweent PreferenceManager.getDefaultSharedPreferences and getSahredPreferences(String name, int mode) ? I thought that the defaultSharedPreferences are someting like global preferences that every application can manipulate. So lets say that I can call a preference

Re: [android-developers] Shared Preferences

2012-10-11 Thread Mark Murphy
On Thu, Oct 11, 2012 at 10:13 AM, Mario Bat batfudba...@gmail.com wrote: Hi, what is the difference betweent PreferenceManager.getDefaultSharedPreferences and getSahredPreferences(String name, int mode) ? The first is the default (e.g., what PreferenceActivity will use). The second uses a name

[android-developers] Shared Preferences

2012-02-07 Thread ajay talreja
This code is not working for mei'm trying to use Shared preferences to store long values.the code is correct and is launching successfully when i switch from long to int valuesplease help package d.preferencesdemo1; import android.app.Activity; import

Re: [android-developers] Shared Preferences

2012-02-07 Thread poncho
Hi, The code itself is fine except that you don't print the exception. If you would log the exception you can see (in the LogCat) that the run-time is throwing some kind of a ParseException. This is since users (usually) don't type 'L' at the end of their numeric input, even when it's long.

[android-developers] Shared preferences and integer values

2011-08-13 Thread Kristoffer
Hello. Iam using shared preferences to store some values. final SharedPreferences pref = getSharedPreferences(MyPref, MODE_PRIVATE); final SharedPreferences.Editor edit = pref.edit(); edit.putInt(Int_value, 1); edit.putString(String_Value, test string); edit.commit(); i look in the xml file

Re: [android-developers] Shared preferences and integer values

2011-08-13 Thread Appaholics
Most probably your Int_Value doesn't exist. In this case the number you specified, 200, will be assigned instead. Thanks On Sat, Aug 13, 2011 at 12:52 PM, Kristoffer kris.isak.v...@gmail.comwrote: Hello. Iam using shared preferences to store some values. final SharedPreferences pref =

Re: [android-developers] Shared preferences in a library

2010-10-29 Thread TreKing
On Tue, Oct 26, 2010 at 8:59 AM, BlackNeko sokl...@gmail.com wrote: Now, I want to use the shared preferences to get some settings and use them for doing calculations in my lib, and I've been trying but can't get a valid context to use in getDefaultSharedPreferences(). Any ideas? public

[android-developers] Shared preferences in a library

2010-10-28 Thread BlackNeko
I made a library that I access and use across my app. My code looks something like this: package com.android.foobar; import android.content.SharedPreferences; import android.preference.PreferenceManager; public class Library{ int someVar; public Library() {

[android-developers] Shared preferences not accessible in service

2009-03-03 Thread Shadakshari Hiremath
Hello Android, We are using SharedPreferences(Not default preferences.) to store our application related settings. These settings are not accessible in the background service as the application context is different from service context. It always returns the default values. We want to have our

[android-developers] shared preferences between applications

2008-11-14 Thread Jason Proctor
i'm using java.util.prefs.Preferences to maintain my apps' preferences, but it seems like one app can't read another's preferences, even if the path to them is the same. is this intended? should i be using a different root than userRoot() ? tx