iOS Question Can't access files in DirAssets

RVP

Active Member
Licensed User
Longtime User
I have a weird error that just started occurring, it seems that the files in DirAssets assets are not accessible by my app, Images that I have used on forms are not showing up, and there is an error in the log indicating they couldn't be loaded.


B4X:
Error loading bitmap: Error opening stream: Error Domain=NSPOSIXErrorDomain Code=2 "No such file or directory" UserInfo={_kCFStreamErrorDomainKey=1, _kCFStreamErrorCodeKey=2}

In addition when I try to copy any file from DirAssets to DirDocuments I get an error saying it is unavailable, although it is clearly in the Files folder, and included on the files tab.

I have synced the files folder, as well as cleaned it of unused files. Also cleaned the project. No difference.

If I remove the app completely and reinstall it works, but this might be an issue for my users as they would loose their data doing this if it was required.

Any idea why the app wouldnt be able to access the DirAssets folder?
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
If I remove the app completely and reinstall it works, but this might be an issue for my users as they would loose their data doing this if it was required.
This is the solution. It will never happen to your users as it is a debugger issue. The debugger avoids sending the asset files each time. In some cases the debugger things that the file was copied successfully and therefore will not copy the file again.
 
Upvote 0
Top