Erel has locked the ExternalStorage thread so I can't comment there but I'm afraid he hasn't included the fix for the problem of repeated requests to grant permission because of differing prefixes to the saved and requested Uris.
https://www.b4x.com/android/forum/threads/solved-trouble-with-external-storage-class.101657/
In SelectDir
In ion_Event
https://www.b4x.com/android/forum/threads/solved-trouble-with-external-storage-class.101657/
In SelectDir
B4X:
'Dim s As String = u 'ignore Originally
Dim temp As Object = u ' Erel's Solution
Dim s As String = temp
In ion_Event
B4X:
'PersistantUri = treeUri 'ignore Originally
Dim temp As Object = treeUri ' Erel's solution
PersistantUri = temp