Map API

Nutiteq Maps Lib SDK enables developing advanced mobile mapping applications.
Platforms: Android, RIM BlackBerry, Java ME (J2ME)
Download maps API SDK »
Untitled Document

Products

» View demos
» Downloads

Uudised

Viimane: Tue, 6 Dec 2011 18:37:53
Teema: New BlackBerry sample app
Veel uudiseid »

Map Lib SDK code tips

Using Google My Maps data in your midlet

You can publish Google My Maps data to your mobile using following steps.

Quick summary:

1. Create My map using maps.google.com. You can use points, lines and polygons, and also styles.

2. Take KML URL from link "View in Google Earth" (with Firefox: right-click to link and Copy link location)

3. Replace here one parameter value: output=nl with output=kml.

4. Put the new link to your Midlet code, so it will be:
mapItem.addKmlService(new KmlUrlReader(
"YOUR URL HERE", false));

5. Compile and run your code. Check the result. It could be that some styles are rendered slightly differently, depending on target device. You may need to adjust styles for required output.

Lisa kommentaar

I have watched this video and

I have watched this video and i have tried to add to my midlet mymap with kml, but the result don't show me the specified map...why???
I use WTK...help me please...
This is the link that i copy after created mymap.

mapItem.addKmlService(newKmlUrlReader("http://maps.google.it/maps/ms?ie=UTF8&hl=it&msa=0&output=kml&msid=105913891935883158815.00046dce884d322a91414",true));

You must add & to end of the

You must add & to end of the URL, so correct is:
mapItem.addKmlService(new KmlUrlReader("http://maps.google.it/maps/ms?ie=UTF8&hl=it&msa=0&output=kml&msid=105913891935883158815.00046dce884d322a91414&",true));

/JaakL