Welcome!

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

Java Development

Reply
Developer
omri
Posts: 74
Registered: ‎07-17-2008
My Device: Not Specified

Move resource files (icons) to the microSD card

[ Edited ]

Hey everyone,

i would like to support an option to move the application icon resources to the microSD card in order to save memory.

what is the preffered way to do so, while still giving the option to use the resources, if a microSD card is unavailible,

Thanks in advance, Omri.

Message Edited by omri on 09-12-2008 03:55 PM
Please use plain text.
Developer
omri
Posts: 74
Registered: ‎07-17-2008
My Device: Not Specified

Re: Move resource files (icons) to the microSD card

Any suggustions?

I guess other developers also want to make as little of a memory footprint as possible.

Please use plain text.
Developer
richard_puckett
Posts: 191
Registered: ‎04-03-2008
My Device: Bold 9700

Re: Move resource files (icons) to the microSD card

One option is to just download the resources from the net as part of an initialization phase when your app is first launched.  This would allow you to store your resources to the SD card (if present) or to built-in flash if SD isn't there.  The big downside to this is that it requires networking which, ironically, can be tricky on a BlackBerry.

 

Another option might be to create a "library" project which simply contains all your resources (analogous to how language resources are used).  You'd then add that project to your build and have it installed along with your app.  When your app starts you read all the resources out and save them to the SD if it's there, and then use CodeModuleManager to delete the library module.

 

Of course, in any event, you need to bear in mind that if the user swaps their SD card your app might get rendered useless.

Please use plain text.