0

I am working on Sdcard Dignostics functionality.I need to perform sdcard read and write functionality in kitkat and lollipop device.There is no direct way to perform read and write in kitkat and lollipop.

But i am able to do this in kitkat following way:

-->Adb shell mkdir stoare/extSdCard/Android/data/com.sample.demo(your package name)

Then we can perfrom read write operations in com.sample.demo folder.

For lollipop using DocumentFile class we can perfrom read and operations for this we need user interaction.

Now my problem is with out user interaction we need to perform read and write,can you please infrom any alternate way like above kitkat procedure.

Thanks in advance

KomalG
  • 808
  • 9
  • 18

1 Answers1

0

That is the design of Lollipop. There is no way to workaround that. The user interaction for giving permission through SAF is anyway needed only once.

More info : How to use the new SD card access API presented for Android 5.0 (Lollipop)?

Community
  • 1
  • 1
somesh
  • 2,509
  • 3
  • 16
  • 24