Reputation: 505
I'm developing an app where I need to create a folder in the Android/obb directory and copy some files into it. The goal is to install a game or an app on the user's device that requires additional data files in the Android/obb folder.
I have already obtained all the necessary permissions from the user, including manageExternalStorage, but although the user accept the permission, I can't create folder in Android/obb folder. I'm surprised how third-party stores can easily install an app along with the OBB file.
Here’s a summary of what I need to achieve: Create a specific folder (e.g., Android/obb/com.example.mygame) in the Android/obb directory. Copy app data files into this folder.
What I’ve Tried: Using the standard file operations in kotlin, but I’m encountering permission issues.
Question:
How can I create a folder and copy files to the Android/obb directory? Is there a specific method or workaround to achieve this? Any code examples or guidance would be greatly appreciated!
Upvotes: 1
Views: 146