How to grant write access to external SDcard using ADB in Android tv? I can't get ES file explorer and winrar to write (copy or cut from internal storage and paste to external storage) to SDCard external storage in Android TV. It says that there will be an "open from" window where I can enable it, but the window won't appear like it did in my android tablet. Is there an ADB command to grant writing access to external SDCard?

I tried to use these commands:

adb shell appops set com.estrongs.android.pop WRITE_EXTERNAL_STORAGE allow
adb shell appops set com.estrongs.android.pop READ_EXTERNAL_STORAGE allow


That was the code for es file explorer, for winrar I just replace com.estrongs.android.pop with com.rarlab.rar The codes executed with no errors, however, I still can't write to the external SDcard, the suggestion to enable it in the supposedly upcoming popup window still appears and the popup window still did not appear. Please help
Android Marshmellow (API 23) or above you need to grant runtime permission. This can be done through an adb shell with the command:

adb shell pm grant com.your.app.package android.permission.WRITE_EXTERNAL_STORAGE


If you ever need to revoke the permission the use this command:

adb shell pm grant com.your.app.package android.permission.READ_EXTERNAL_STORAGE