1

I am using CSMapAnnotation classes for different purposes. Now I have to show route between two locations. I do have latitude and longitude for both of the locations.

Can any one please help the best way to achieve that ?

Tariq
  • 9,861
  • 12
  • 62
  • 103

1 Answers1

1

You can use this example:

http://blog.kadirpekel.com/2010/05/30/drawing_routes_onto_mkmapview_using_unofficial_google_maps_directions_api/

It will call the routing api and parse the result.

Then a new layer is added above the map with the route between A and B.

j_freyre
  • 4,623
  • 2
  • 30
  • 47
  • 1
    I have added classes in my project. But i think its showing wrong path. Suppose two locations are very close to each other and instead of simple path its showing long and erroneous path. – Tariq Mar 29 '11 at 08:50
  • Hey Now i am stuck in changing pin colors. I have to show 1 in red and 1 in green. I have tried using viewForAnnotation delegate but its not helping me – Tariq Apr 27 '11 at 09:44