BlackBerry Deployment

From HTML5 Builder
Jump to: navigation, search

This page covers deployment of mobile applications for BlackBerry devices.

Contents

Export your Project

Generation

Go to Home > Deploy to Mobile, and follow these steps:

  1. On the Welcome page, choose BlackBerry as target device and click Next.
  2. On the Application Setup page:
    1. Set Index page to the page to be displayed first when users run your application.
    2. In the Application name field, type your application’s name.
    3. In the Company name field, type the name of your company.
    4. Click Next.
  3. On the BlackBerry Graphics page, you can setup icons and splash screens for your application.
    1. To choose an image file for a field:
      1. Click .
      2. Go to image’s location, and select it.
      3. Click OK.
    2. Click Next.
  4. On the Target Destination page:
    Note: The folder you choose will be where all files and folders will be generated. You might want to create a new folder for your build.
    1. Optionally, change destination folder:
      1. Click .
      2. Go to folders location, and click OK.
    2. Click Next.

Configuration

On the Export page, your PhoneGap folder will be exported to the destination folder as www, and archived as a Your Application.zip file there too. Wait for the process to finish.

There are some things you might want to do on the www folder before you continue, some of the possibilities are listed below.

Once you are ready, if you changed anything on the www folder, generate a new Your Application.zip archive with its contents (there are several tools you can use for that task).
Warning: You must create the archive from the contents of the www folder, not from the folder itself.

External Resources

If you included in your application any external resources, like image files, you must copy them into www.

Screen Orientation

By default, your application is supposed to work both on portrait and landscape orientations. If you want to support only one orientation, edit the config.xml file you will find inside the www folder, and add the following line inside the <widget></widget> tags:

<rim:orientation mode="orientation"/>

Replace orientation by either portrait or landscape.

Build your Application

Once the PhoneGap project folder is ready, you can build the final application either remotely, using the PhoneGap Build service, or locally. If your system is configured to build BlackBerry applications, you will be given both choices. Else, the PhoneGap Build service will be selected for you.

See PhoneGap Build for instructions on how to build your application remotely, or continue reading to build it locally.

Local Build

Note: You must prepare your system to build your applications locally. See BlackBerry Setup.

Click Next on the Export page and, on the Compile page, wait for the build process to end. Then click Finish.

Now, in your destination folder you will find two additional folders: OTAInstall and StandardInstall. You can now run StandardInstall\YourApplication.cod to test your application. For a release build you can deploy, you must manually build your application.

Build

  1. Open a terminal: Start > All Programs > Accessories > System Symbol.
    Warning: In Windows Vista, Windows 7 and Windows 8 your must run it as administrator.
  2. Run cd SDK_directory, where SDK_directory is:
    • In 32-bit systems: C:\Program Files\Research In Motion\BlackBerry WebWorks SDK version
    • In 64-bit systems: C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks SDK version
  3. Run bbwp zip_file -o destination_folder -g password, where:
    • zip file is the path to the .zip file with www contents inside.
    • destination folder is the folder where you want built application to be moved.
    • password is your password.
      Note: You can omit the -g password part if you are only building for testing.

You will find your application in destination_folder\StandardInstall\zip_filename.cod. You can now deploy that .cod file to the App World. To do so, check the steps in BlackBerry Documentation: us.blackberry.com/developers/appworld/.

Run

  1. Connect your BlackBerry device to your computer through USB, or start the emulator and select Simulate > USB Cable Connected.
  2. Open a terminal: Start > All Programs > Accessories > System Symbol.
    Warning: In Windows Vista, Windows 7 and Windows 8 your must run it as administrator.
  3. Run cd SDK_bin_directory, where SDK_bin_directory is:
    • In 32-bit systems: C:\Program Files\Research In Motion\BlackBerry WebWorks SDK version\bin
    • In 64-bit systems: C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks SDK version\bin
  4. Run .\JavaLoader.exe -u load file.cod, where:
    • file.cod is the path to the .cod file you built.
Emulator

You will find emulator launcher, fledgelauncher.exe, in the following folder:

  • In 32-bit systems: C:\Program Files\Research In Motion\BlackBerry WebWorks SDK version\simpack\simversion
  • In 64-bit systems: C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks SDK version\simpack\simversion

Start the launcher, select the emulator you want to launch, and click Go.

Personal tools