the map wasnt initialized...
thank you!!!!

On Apr 30, 2:35 pm, Arothian <[email protected]> wrote:
> Try :
>
>  var point:KmlPoint = KmlPoint(geometry);
>  var num1:Number = point.coordinates.coordsList[0].lat
>  var num2:Number = point.coordinates.coordsList[0].lon
>  var latlng:LatLng = new LatLng(num1,num2);
>  var mark:Marker = new Marker(latlng);
>  obj.mapObjs.push(mark);
>  updateBounds(obj, new LatLngBounds(latlng, latlng)); //What is this
> doing?
>  map.addOverlay(mark);
>
> Also, make sure that the map has been initialized before you add any
> overlays.
>
> On Apr 30, 8:49 am, jm <[email protected]> wrote:
>
> > forgot to include the code...
>
> >  var point:KmlPoint = KmlPoint(geometry);
> >       var num1:Number=point.coordinates.coordsList[0].lat
> >       var num2:Number=point.coordinates.coordsList[0].lon
> >       var latlng:LatLng = new LatLng(num1,num2);
> >      var   mark = new Marker(latlng);
> >       obj.mapObjs.push(mark);
> >       updateBounds(obj, new LatLngBounds(latlng, latlng));
> >       map.addOverlay(obj.mapObjs[obj.mapObjs.length -1]);
>
> > On Apr 30, 1:46 pm, jm <[email protected]> wrote:
>
> > > Hi
>
> > > I'me new to the Gmaps Api in flash
>
> > > I've been trying to make it work and so far so good.
> > > I'm loading kml from the server, and it works just fine.
>
> > > I'm using the example in 
> > > here:http://gmaps-utility-library-flash.googlecode.com/svn/trunk/examples/...
>
> > > but I', trying to adapt it to cs3...
>
> > > I get this error message:
> > > TypeError: Error #1009: Cannot access a property or method of a null
> > > object reference.
> > >         at com.google.maps.overlays::Marker()
>
> > > Here is the code with some modifications
>
> > > Thanks
>
> > > jm
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Maps API For Flash" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-maps-api-for-flash?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to