And this sentence says another different question.
Can you exactly say what you want to achieve? If you want to get a full file list without knowing its directory, just enable includeSubdirectories and set directoryName to “/” or “/storage/emulated/0/”
Also it is normal to your app crashing because you are trying to play a lot of files at the same time with one component since loops has no any additional delay.
But inside Foreach there is an IF that is only true when the file name coincides with the item in the list. The names are long and without spaces and there are no two equal, so it should reproduce only one. In fact in the companion only one is reproduced and everything works perfect. It is when I compile the apk that the application closes itself…
Since you don’t have permission to READ from external storage, the (not shown) error is: java.lang.NullPointerException: Attempt to get lenght of null array at com.puravidaapps.TaifunFile.getList(TaifunFile.java.xxx)
But this error message is not displayed because the app crashes immediately.
Yes, but the question should be correct here:
Was the permission READ_EXTERNAL_STORAGE requested before TaifunFile.FileListAsync is triggered and then also granted?
This is obviously not the case, as I have shown.