B4A + B4i example: https://www.b4x.com/android/forum/threads/b4x-texteditor-save-and-load-external-files.132731/#post-838166 List of classes or libraries that can be used to access secondary storages: ContentChooser (Phone libray) - allows the user to select a resource or file using external...
www.b4x.com
The SaveAs Sub works correctly, but when the user has used OpenWith or load, there is a path and there is no need for SaveAs and it must be saved directly. how must I make save Sub from existing path without using content resolver. Thanks.
Dim out As OutputStream = ctxt.InitializeContext.RunMethodJO("getContentResolver", Null).RunMethod("openOutputStream", Array(jo.RunMethod("getData", Null)))
You need to keep the return value of jo.RunMethod("getData", Null). You can later try to use it again. Note that there is no guarantee that it will work. It depends on the external app that actually manages the url. You don't have direct access to the file system.
Another option is to use ExternalStorage. Once the user chose a folder, you can access it without asking for another approval (in most cases).
Before we start: External storage means a real sd card or a connected mass storage USB device. This class can also be used to access the secondary storage (File.DirRootExternal). This becomes relevant with newer versions of Android that restrict direct access. It has nothing to do with runtime...
Storge library does not have a practical example project, if you could create a project like a text editor for Storge, it would be great.
In addition, I want to have both save and storage sample.