yes, it is possible to create and copy file to internal storage
B4X:
'create NewFolder directory
File.MakeDir(File.DirInternal,"NewFolder")
'copy file to newly created folder
File.Copy(File.DirAssets,"a.txt",File.DirInternal & "/NewFolder", "a.txt")
or
'make sure copy file finished before next code
Wait For (File.CopyAsync(File.DirAssets, "a.txt", File.DirInternal & "/NewFolder", "a.txt")) Complete (Success As Boolean)
You can find the file at app instalation directory, with file manager go to: Internal Storage/Android/Data/[your app package name]/files
Edited:
sorry i give you wrong information relate to app instalation folder. the correct was app instalation folder will remain invisible for other app to read (except you had root access) since it store in internal file system.
Folder Internal Storage/Android/Data/[your app package name] is locate in External file system which can be access by other app. to access this folder please see post #9
first: I can't find the folder in app package name
second: the app package name is different from the one I write it
it appears as Internal Storage/Android/Data/anywheresoftware.b4a.b4abridge/
how to change this (anywheresoftware.b4a.b4abridge) to the package name that I write
To know and define package name... Go to Project menu -> Build Configurations (Ctrl + B), in the Package section - that would be your app package name.
Yes I did that but I don't know why the package name is not changing
I use this as package name (com.mas.myapp.android) I don't know if this is valid for a package name
Dim rp As RuntimePermissions
rp.GetSafeDirDefaultExternal("")
File.MakeDir(File.DirDefaultExternal, "NewFolder")
File.Copy(File.DirAssets,"a.txt",File.DirDefaultExternal,"NewFolder/a.txt")
The full path would be in: Internal Storage/Android/data/[package name]/files/NewFolder/a.txt