ContactPickerOptions
The ContactPickerOptions object contains options available for invoking the contact picker, see blackberry.pim.contacts.invokeContactPicker().
Supported Platform(s)
| - BlackBerry 10 |
| API | BB5.0 | BB6.0 | BB7.0 | PB1.0 | PB2.0 | BB10 | Ripple |
|---|---|---|---|---|---|---|---|
| confirmButtonLabel | Y | ||||||
| fields | Y | ||||||
| mode | Y | ||||||
| title | Y | ||||||
| MODE_SINGLE | Y | ||||||
| MODE_MULTIPLE | Y | ||||||
| MODE_ATTRIBUTE | 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 | BB5.0 | BB6.0 | BB7.0 | PB1.0 | PB2.0 | BB10 | Ripple |
|---|---|---|---|---|---|---|---|
| <feature id="blackberry.pim.contacts" /> | Y |
| Permission Elements (PlayBook and BlackBerry 10+) |
|---|
| This API does not require a <permission> element to be declared in the configuration document of your BlackBerry WebWorks Application. |
Properties
| String | confirmButtonLabel |
| String[] | fields |
| Number | mode |
| String | title |
Constants
| Number | MODE_SINGLE |
| Number | MODE_MULTIPLE |
| Number | MODE_ATTRIBUTE |
Properties
String
confirmButtonLabel
A custom label to be displayed in the confirmation button of the picker.
If not specified, the default label will be used. Note that the confirmation button is only displayed if the picker is invoked in MODE_MULTIPLE.
| Supported Platforms | |
|---|---|
| - BlackBerry 10 | |
String[]
fields
An array of field names (e.g. phoneNumbers, emails etc.) that should be used for filtering the contacts in the picker. (The names correspond to the field names in the blackberry.pim.contacts.Contact object.) A contact must have one or more of the attributes in this set in order to be displayed. If mode is MODE_MULTIPLE, this would determine the attributes to be shown in the picker. Fields must be specified in order for the picker to be invoked in MODE_MULTIPLE.
| Supported Platforms | |
|---|---|
| - BlackBerry 10 | |
Number
mode
Describes the mode of the contact picker. Possible values are: MODE_SINGLE, MODE_MULTIPLE or MODE_ATTRIBUTE. If mode is not specified, the picker will be invoked in MODE_SINGLE.
| Supported Platforms | |
|---|---|
| - BlackBerry 10 | |
Constants
static
Number
MODE_SINGLE
This mode allows the user to select a single contact.
The selection will complete as soon as a contact is selected.
| Supported Platforms | |
|---|---|
| - BlackBerry 10 | |