Blackberry JAVA DEVELOPMENT ENVIRONMENT - - GPS AND MAPS - DEVELOPMENT GUIDE Manual de usuario Pagina 19

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 30
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 18
For RIM and BlackBerry partner use only. Beta documentation. Content and software are subject to change.
19
3: Displaying location information on a BlackBerry device
Open BlackBerry Maps to display the default map view
> To display the last map that the BlackBerry® device user viewed, from a BlackBerry Application, invoke
invokeApplication() using a new MapsArguments object that does not contain any arguments, for
example,
Invoke.invokeApplication( Invoke.APP_TYPE_MAPS, new MapsArguments() );
View a sample application that displays the default map
1. From the BlackBerry® Integrated Development Environment, start the BlackBerryMapsDemo project.
2. In the BlackBerry Smartphone Simulator, click BlackBerry Maps Demo.
3. Open the menu and click Invoke Default.
4. Open the menu and click View Map. BlackBerry® Maps displays the following map:
Open BlackBerry Maps to display a location on a map
1. Create a String that contains location information for one location, for example
String document = "<lbs><location lon='-7938675' lat='4367022' label='Toronto, ON'
description='Toronto' zoom='10'/></lbs>";
2. Invoke invokeApplication() using the APP_TYPE_MAPS constant parameter, a new MapsArguments object
that uses the
ARG_LOCATION_DOCUMENT property and the location String, for example
Invoke.invokeApplication(Invoke.APP_TYPE_MAPS, new MapsArguments(
MapsArguments.ARG_LOCATION_DOCUMENT, document));
View a sample application that displays a location on a map
1. From the BlackBerry® Integrated Development Environment, start the BlackBerryMapsDemo project.
2. In the BlackBerry Smartphone Simulator, click BlackBerry Maps Demo.
3. Open the menu and click Invoke Location Document.
Vista de pagina 18
1 2 ... 14 15 16 17 18 19 20 21 22 23 24 ... 29 30

Comentarios a estos manuales

Sin comentarios