Android Question Rotate a Google Maps Marker

Discussion in 'Android Questions' started by piedy, Jan 2, 2014.

  1. piedy

    piedy Member Licensed User

    Hi,

    I'm currently experiencing an error rotating a marker on a google map. It compiles fine but during execution, I get an error message:

    java.lang.NoSuchMethodError: com.google.android.gms.maps.model.MarkerOptions.rotation

    Any help appreciated.

    Thanks.

    Full code below (gmapExtras is a object of type GoogleMapExtras)

    Code:
    Dim MarkerOptions1 As MarkerOptions
    MarkerOptions1.Initialize
                  
    MarkerOptions1.Position2(lat, lng).Visible(
    True)
                  
    Dim BitmapDescriptor1 As BitmapDescriptor
    Dim BitmapDescriptorFactory1 As BitmapDescriptorFactory
    BitmapDescriptor1=BitmapDescriptorFactory1.FromAsset(
    "vor.png")
    MarkerOptions1.Icon(BitmapDescriptor1)
    MarkerOptions1.Rotate(
    90)
                  
    Dim Marker1 As Marker = gmapExtras.AddMarker(gmap, MarkerOptions1)
     
  2. Erel

    Erel Administrator Staff Member Licensed User

    Try to update the device Google Play Services (from Google Play).
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice