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

New Contributor
Posts: 6
Registered: ‎11-16-2011
My Device: developmer
My Carrier: developer

Adding files to storage in simulator



I am pretty new to blackberry development. I need to save some pdf, word, excel files from my computer hard drive to black berry simulator environment. The requirement is such that I need to transfer these files using FILE api in blackberry to some remote server. How can I save some of these sample test files from my computer hard drive to be avaiable in simulator storage card so that I can read those from my bb application.


Thanks in advance to all the help.


Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: Adding files to storage in simulator

BlackBerry Development Advisor
Posts: 118
Registered: ‎11-01-2011
My Device: N/A
My Carrier: Rogers

Re: Adding files to storage in simulator

This can also be done via the Simulate->Change SD Card menu in the simulator.  When the simulator is loaded click on "Add Directory", choose a temporary folder such as c:\tmp-sdcard, and then select the mount button.  Once mounted, you can put place your files in C:\tmp-sdcard\BlackBerry\documents and they will appear inside the simulator.  


On 7.0/7.1 simulators you can also select the "Remount SD Card on Startup" so your settings are persisted every time you run the simulator.