Issue
Here is my code :
public class MyGoogleMapActivity extends FragmentActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.googlemap);
GoogleMap map = ((SupportMapFragment) getSupportFragmentManager().findFragmentById(R.id.map)).getMap();
map.setMyLocationEnabled(true);
LatLng Paris= new LatLng(64.711696, 12.170481);
map.addMarker(new MarkerOptions().title("LolluSaba").position(Paris));
LatLng Cinema= new LatLng(34.711696, 2.170481);
map.addMarker(new MarkerOptions().title("Pseudo").position(Cinema));
}
}
And i like to draw a route from Paris to Cinema. How can I do it very simply ?
Solution
As you have two points so send it through google json which provides to draw route between two points. See this example.
Route direction between two location
Answered By - Shadow
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.