Why your app can’t see SD Card on Android Marshmallow

On Android Marshmallow just having the READ_EXTERNAL_STORAGE in your AndroidManifest.xml is not enough anymore to read the SD Card. Your app now needs to explicitly request this permission from the user. This is true even if your app was built with targetSDKVersion well below Marshmallow.

This can be fixed in the application by adding the following code into your main activity (or into an activity which attempts to access SD Card).