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 Knowledge Base

How to Extract Application Files

by BlackBerry Development Advisor on ‎01-09-2012 10:34 AM - edited on ‎05-07-2012 10:12 AM by Retired (8,245 Views)



This article applies to the following:

  • BlackBerry® Tablet OS
  • BlackBerry® Native SDK
  • BlackBerry® WebWorks™ SDK for Tablets
  • BlackBerry® SDK for Android™ Apps



BlackBerry Tablet applications run in sandboxes, with each one with having its own private area to store files that is accessible only to that application.  This area can be used to store any type of file such as a database, image or log file.  Each application also has its own log file created by default that can be used to record data for the purposes of testing and debugging.  For example, native applications standard out and standard error streams are recorded in the log file.


Unless you code a way to display these files in your application, there is no way to see them on the device. However, you can extract them to view them on your PC.


Note:  Before you begin, ensure that you have installed a debug version of your application.  This process will not work on a release build of an application.  The device will also need to be put into Developer Mode.



Using the NDK


The BlackBerry Native SDK provides a graphical user interface to copy files to and from a BlackBerry Tablet.  Use the following steps to copy a file.


  1. Perform a Run As or Debug As on your application and deploy a debug release to your BlackBerry Tablet.
  2. Click on the Window menu.
  3. Choose Show View -> Other.
  4. Expand QNX.
  5. Select Target File System Navigator and click OK.
  6. In the Target File System Navigator window expand Sandboxes and then expand the folder for your application.
  7. Select the folder that contains the file you wish to copy.
  8. Right click on the file you wish to copy and choose Copy To.  You can also drag and drop files to and from this window.


Using the Command Line


The BlackBerry Native SDK, BlackBerry® Tablet OS SDK for Adobe® AIR®, BlackBerry WebWorks SDK for Tablets and BlackBerry SDK for Android Apps all include a command line application that can be used to copy files from a BlackBerry Tablet.  The following command shows an example of copying the application log file.  This command requires a copy of the BAR file installed on the device to be available on the computer executing the command.


blackberry-deploy -getfile logs/log logFileOnPC.txt -device -password YOUR_PASSWORD YOUR_BAR_FILE.bar


You can also use the -putfile command to upload files to a BlackBerry Tablet.


Users Online
Currently online: 12 members 607 guests
Please welcome our newest community members: