1

I got a problem on the code, and I don't know what's going wrong with it. Here it is:

mMap.addMarker(new MarkerOptions()
    .position(new LatLng(14.590230, 120.983149))
    .title("SM City Manila"))
    .icon(BitmapDescriptorFactory
    .fromResource(R.drawable.blue));

The problem is on line 4, in which errors prints: The method icon(BitmapDescriptor) is undefined for the type Marker.

Whymarrh
  • 13,139
  • 14
  • 57
  • 108
  • http://stackoverflow.com/questions/14599842/how-to-display-multiple-markers-with-different-icons-in-google-maps-android-api – IntelliJ Amiya Jun 29 '14 at 05:33

1 Answers1

1

Try this .

 private static final LatLng MyPlace = new LatLng(14.590230, 120.983149);
              private Marker melbourne = mMap.addMarker(new MarkerOptions()
                                        .position(MyPlace)
                                        .title("SM City Manila")                                                      
                                        .icon(BitmapDescriptorFactory.fromResource(R.drawable.blue)));
IntelliJ Amiya
  • 74,896
  • 15
  • 165
  • 198