0

I want to access the folder where my app is installed and has it's data, cache etc. How do I do that? I am currently using this but this only specifies a path on the SD card.

   File dir = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS);
File FileDirectory = new File(dir, "winrar-x64-560.exenb");
user9555243
  • 155
  • 1
  • 3
  • 12

1 Answers1

1

You can access this way:

File file = getExternalFilesDir(null);

OR, TRY THIS

File file = new File(Environment.getExternalStorageDirectory()+"/Android/data/"+getPackageName());

Regards.

olajide
  • 972
  • 1
  • 13
  • 26