I have tried to delete the my folder from the SD card when app is uninstalled, but I didn't find that the app is uninstalled. Can anyone help me?
Asked
Active
Viewed 47 times
-1
-
4Possible duplicate of [Perform a task on uninstall in android](http://stackoverflow.com/questions/3013823/perform-a-task-on-uninstall-in-android) – 1615903 Nov 23 '15 at 11:04
-
Could you add to your question any code that you have tried to get this working please. – Peter Nov 23 '15 at 11:14
1 Answers
1
Usually there is not need to do such a task. Application specific files should be stored in an application directory.
You can get such a directory via getExternalFilesDir or getFilesDir (). There are some other dirs. Take a look at the ContextWrapper class for more information.
The files inside these dirs will be deleted when the application is uninstalled.

daemmie
- 6,361
- 3
- 29
- 45