I know this question has been answered several times over, but no answers seem to help. I've tried using multiple approaches, and most recently this:
Getting the filenames of all files in a folder
which also redirects to another thread with code that would not work for me either.
My app keeps crashing, and the error says it's a null pointer.
I tried checking for a directory
File dir = new File("C:\\Users\\myName\\files");
//Log.d("filePath:", filePath);
if(dir.isDirectory()) {
Log.d()
}
but there was no log from within my if statement. Apparently it's not being take as a directory. I must be overlooking something incredibly simple.