On Fri, Sep 7, 2012 at 10:13 AM, Abhishek Kumar Gupta
<[email protected]>wrote:

> I am unable to delete .bak file of the
> sharedpreferences(profile_preference) of application having package
> "com.android.blesettings". I have tried the following code:
>
>                      File file = new
> File("/data/data/com.android.blesettings/shared_prefs/profile_preference.xml.bak");
>                       file.delete();
>

What makes you think you can just arbitrarily delete the files of another
application?

delete() return true or false if it succeeded or not. Check it. It's
probably always false because you have no permission to be doing this.

-------------------------------------------------------------------------------------------------
TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to