Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Posts: 33
Registered: ‎01-12-2011
My Device: Torch
Accepted Solution

Writing access to asset folder? Possible or not?


I have several JSON files in the app/native/assets/data folder which contain data for my application. In the app sources they are in the assets/data folder. I read that runtime only access to the root folder data will be allowed. However in both simulator and DevAlpha device i am able to write to the assets/data folder. Will this be different for production devices or has this changed? 

Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Writing access to asset folder? Possible or not?

You can read about the various folders that are available and the restrictions on them: http://developer.blackberry.com/native/documentation/bb10/com.qnx.doc.native_sdk.devguide/com.qnx.do...


The fact that you can write to the folder now is because your app is built with a "development mode" flag true. Once you export as a release build and sign it, that flag is cleared and your app is installed with the app/ folder read-only, as described in the page above.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!