Take the 2-minute tour ×

I need to store some data in my Blackberry application so i'm using files,i'm storing these files in the internal memory of the device , but if i uninstalled the application i need these files to be removed too. Is there a way to store the files in the same path of the application package , or any other way to delete them if the application was uninstalled?

This is the path which i'm using:

    try {
    fileconn = (FileConnection) Connector.open("file:///store/home/user/data.txt");
share|improve this question
add comment

1 Answer

What kind of data are you storing? If you can store the data in the app's PersistentStore instead, it will automatically be deleted when the app is uninstalled.

share|improve this answer
I'm caching a lot of data, Xml files, so i need to keep them in the internal memory,i found some code about CodeModuleListener, but i did not figure out how to use it. –  Reham May 14 '12 at 7:05
add comment

Your Answer


