Invoke
The Invoke object contains methods that interact with other applications on a BlackBerry PlayBook.
The invoke() method on the invoke object allows you to pass arguments to the target application. The types of arguments can be one of: blackberry.invoke.AddressBookArguments, blackberry.invoke.BrowserArguments, blackberry.invoke.CalendarArguments, blackberry.invoke.CameraArguments, blackberry.invoke.JavaArguments, blackberry.invoke.MapsArguments, blackberry.invoke.MemoArguments, blackberry.invoke.MessageArguments, blackberry.invoke.PhoneArguments, blackberry.invoke.SearchArguments, and blackberry.invoke.TaskArguments.Supported Platform(s)
- BlackBerry OS 5.0+
- BlackBerry PlayBook
- Ripple Emulator
API | OS 5.0 | OS 6.0 | OS 7.0 | PlayBook | Ripple |
---|---|---|---|---|---|
invoke | Y | Y | Y | Y | Y |
APP_ADDRESSBOOK | Y | Y | Y | Y | |
APP_BLUETOOTH_CONFIG | Y | Y | Y | Y | |
APP_CALCULATOR | Y | Y | Y | Y | |
APP_CALENDAR | Y | Y | Y | Y | |
APP_CAMERA | Y | Y | Y | Y | Y |
APP_MAPS | Y | Y | Y | Y | Y |
APP_MEMOPAD | Y | Y | Y | Y | |
APP_MESSAGES | Y | Y | Y | Y | |
APP_PHONE | Y | Y | Y | Y | |
APP_SEARCH | Y | Y | Y | Y | |
APP_TASKS | Y | Y | Y | Y | |
APP_BROWSER | Y | Y | Y | Y | Y |
APP_JAVA | Y | Y | Y | Y | |
APP_MUSIC | Y | Y | |||
APP_PHOTOS | Y | Y | |||
APP_VIDEOS | Y | Y | |||
APP_APPWORLD | Y | Y |
Configuration Document Settings
To use all of the API described for this object, you must ensure the following settings are in your configuration document:
You must declare the feature element(s) below in your configuration document:
Feature ID | OS 5.0 | OS 6.0 | OS 7.0 | PlayBook | Ripple |
---|---|---|---|---|---|
<feature id="blackberry.invoke" /> | Y | Y | Y | Y | Y |
Permission Elements (PlayBook Only) |
---|
This API does not require a <permission> element to be declared in the configuration document of your BlackBerry WebWorks Application. |
API Summary
Functions
invoke
static void invoke(appType : Number, [args: Object]) |
Supported Platform(s)
- BlackBerry OS 5.0+- BlackBerry PlayBook
- Ripple Emulator
Description
Invokes another application on the BlackBerry Playbook.
Parameter | Type | Description |
---|---|---|
appType | Number | an integer value representing the type of application to launch. Must be one of the 'APP_*' constants. |
args |
Object
Optional |
An arguments object specifying information for the application being invoked. |
Throws | Description |
---|---|
Exception | If values supplied are not correct. |
Constants:
Property | Type | Description | Supported Platform(s) |
---|---|---|---|
APP_ADDRESSBOOK default: 0 | Number |
Constant used to invoke the Address Book.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_BLUETOOTH_CONFIG default: 1 | Number |
Constant used to invoke the Bluetooth Configuration.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_CALCULATOR default: 2 | Number |
Constant used to invoke the Calculator.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_CALENDAR default: 3 | Number |
Calendar.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_CAMERA default: 4 | Number |
Camera.
|
- BlackBerry OS 5.0+
- BlackBerry PlayBook - Ripple Emulator |
APP_MAPS default: 5 | Number |
Maps.
|
- BlackBerry OS 5.0+
- BlackBerry PlayBook - Ripple Emulator |
APP_MEMOPAD default: 6 | Number |
Constant used to invoke the Memopad.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_MESSAGES default: 7 | Number |
Constant used to invoke the Messages Application.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_PHONE default: 8 | Number |
Constant used to invoke the Phone.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_SEARCH default: 9 | Number |
Constant used to invoke the Search.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_TASKS default: 10 | Number |
Constant used to invoke the Tasks.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_BROWSER default: 11 | Number |
Browser.
|
- BlackBerry OS 5.0+
- BlackBerry PlayBook - Ripple Emulator |
APP_JAVA default: 12 | Number |
Constant used to invoke a Java Application.
|
- BlackBerry OS 5.0+
- Ripple Emulator |
APP_MUSIC default: 13 | Number |
Music Application.
|
- BlackBerry PlayBook
- Ripple Emulator |
APP_PHOTOS default: 14 | Number |
Photos Application.
|
- BlackBerry PlayBook
- Ripple Emulator |
APP_VIDEOS default: 15 | Number |
Videos Application.
|
- BlackBerry PlayBook
- Ripple Emulator |
APP_APPWORLD default: 16 | Number |
App World Application.
|
- BlackBerry PlayBook
- Ripple Emulator |
Code Example(s)
<script type="text/javascript"> function startCameraApp() { var args = new blackberry.invoke.CameraArguments(); args.view = blackberry.invoke.CameraArguments.VIEW_RECORDER; blackberry.invoke.invoke(blackberry.invoke.APP_CAMERA, args); } startCameraApp(); </script>
Documentation generated by JsDoc Toolkit 2.4.0 on Sun Dec 30 2012 13:31:18 GMT-0500 (EST)