B4J Question [BANano] File map

micro

Well-Known Member
Licensed User
Longtime User
Hi to all
I proceed with the tests, but just to learn and try something different, I have never seriously developed webapplication (the time available is always short)
The function File it's not used by BANano, then for write and read a file map (in Dir.App or other path) how can i proceed?
I don't know if you need to transform it into json format and write/read it with inlinephp.....
Some simple examples, thanks.
 

micro

Well-Known Member
Licensed User
Longtime User
Ok clear enough, thanks.
but I don't have to choose the file with fileExplorer, I already know the path, so I have to access it directly
but I don't know how to provide the path to BANano
Example:
File "settings.cfg" in BANano.ASSETS_FOLDER
 
Last edited:
Upvote 0

alwaysbusy

Expert
Licensed User
Longtime User
It does not help to know the path if you are not able to access that file from javascript.
This is correct. As I said, without user interaction, a web brower/javascript is not allowed to access anything on your local hard disk. This is browser build-in security so no one can access your private files.
 
Upvote 0

alwaysbusy

Expert
Licensed User
Longtime User
Upvote 0

micro

Well-Known Member
Licensed User
Longtime User
Thanks to all
so it seems to go, returns the promise object with the file data
B4X:
Log(BANano.GetFileAsText($"${BANano.ASSETS_FOLDER}/settings.cfg"$, Null, "UTF8"))
 
Upvote 0

micro

Well-Known Member
Licensed User
Longtime User
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…