2009/3/20 zypsg <[email protected]>

>    Do you mean that use        openFileOutput and      openFileInput to
> save
> my persistent data ?


Yes, and there are other methods for creating databases, getting paths, etc.


>    I have tried these methods.They create file under /data/data/<my
> package>/files/ directory.  I find that when I uninstall the app, the
> file created will be deleted automatically.   That doesn't meet my
> requirement. Because when user reinstall my app, I cannot find the
> setup infomationI my app have written into files.


This is the intended behavior.  Uninstalling an app removes all of its
data.  Otherwise its data is left laying around for the user to manage.
Maybe in the future we will have a UI option to uninstall an app but keep
its data (the package manager can already do this), but this leads to a much
more complicated user experience so it is a low priority.


>    Is there a directory or method to keep the file even if the user
> uninstall my app ,so that I can find previous infomation about my app
> when user install my app again.


No, sorry.  Uninstalling is supposed to clean up everything of the app.

-- 
Dianne Hackborn
Android framework engineer
[email protected]

Note: please don't send private questions to me, as I don't have time to
provide private support.  All such questions should be posted on public
forums, where I and others can see and answer them.

--~--~---------~--~----~------------~-------~--~----~
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