Hi to everyone
I'm trying to apply the method fitBounds with the GoogleMaps library, but an error while trying to initialize the object LatLongBounds procuce.
This is my code
Any ideas?
Thanks in advance
I'm trying to apply the method fitBounds with the GoogleMaps library, but an error while trying to initialize the object LatLongBounds procuce.
This is my code
B4X:
Dim MapBounds As JavaObject
MapBounds.InitializeArray("com.lynden.gmapsfx.javascript.object.LatLongBounds", Null)
For i=0 To MapMarkers.Size-1
Dim MapMarker As MapMarker = MapMarkers.GetValueAt(i)
Dim Point As LatLng = Marker.Position
MapBounds.RunMethod("extend", Array(Point))
Next
Dim jMap As JavaObject = gmap
jMap = jMap.GetField("map")
jMap.RunMethod("fitBounds", Array(MapBounds))
Any ideas?
Thanks in advance