I need to create Intent
which will show me a file picker to choose files inside the specified folder. I used this approach:
Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
Uri selectedUri = Uri.parse(getFilesDir().getAbsolutePath() + "/FILES");
intent.setDataAndType(selectedUri, "*/*");
startActivityForResult(intent, SCRIPT_REQUEST_CODE);
But this didn't open the desired folder.
Can somebody tell how to open the file picker in the specified folder?
UPD: Tried this as were suggested in comments but I can't pick the desired file type with such type in intent.
Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.setType("file/*");
startActivityForResult(intent, YOUR_RESULT_CODE);