Android Question getDirAssets

roberto64

Active Member
Licensed User
Longtime User
Hi, I would like to know where I am wrong in this java code, I state that already BAX the code works as below,
Error
Impossibile copiare ita traineddatajava.io.FileNotFoundException: /data/user/0/b4a.example/files/ita.traineddata (No such file or directory)



 

drgottjr

Expert
Licensed User
Longtime User
as i recall, /data/user/0/b4a.example/files/ita.traineddata is File.DirInternal
 
Upvote 0

roberto64

Active Member
Licensed User
Longtime User
The ita. traineddata must be copied from "DirAssets" to a directory either in the storage or in the smartphone directory. naturally in java code.
thank you
 
Upvote 0

drgottjr

Expert
Licensed User
Longtime User
somewhere you have changed file.dirassets to file.dirinternal. when you try to copy your file from file.dirinternal to some other location, the exception is thrown because there is no file in file.dirinternal. look carefully and slowly at your code (including parts that you did not post). i believe that somewhere you have changed a reference from file.dirassets to file.dirinternal. /data/user/0/b4a.example/files is file.dirinternal
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…