I made a quick demo a few months ago using the API to show my manager
what can be done with it, and it worked fine when I left it, come back
a few months later and it now falls over using clearOverlay()/
removeOverlay() methods of the map.

Using removeMarker() the error is:

ArgumentError: Error #2025: The supplied DisplayObject must be a child
of the caller.
        at flash.display::DisplayObjectContainer/removeChild()
        at com.google.maps.wrappers::SpriteFactory/removeChild()
        at com.google.maps.wrappers::ISpriteFactoryWrapper/removeChild()
        at com.google.maps.overlays::Marker/onRemovedFromPane()
        at com.google.maps.overlays::Overlay/set pane()
        at com.google.maps.overlays::Pane/removeOverlay()
        at com.google.maps.core::MapImpl/removeOverlay()
        at com.google.maps.wrappers::IMapWrapper/removeOverlay()
        at fullscreen_google_map_fla::MainTimeline/removeAllMarkers()
        at fullscreen_google_map_fla::MainTimeline/drawMarkers()
        at fullscreen_google_map_fla::MapKey_2/cat1Change()
        at flash.events::EventDispatcher/dispatchEventFunction()
        at flash.events::EventDispatcher/dispatchEvent()
        at fl.controls::LabelButton/toggleSelected()

Using code on the timeline of a cs4 as3 fla: http://pastie.org/611185

The above code is where I've tried to use removeOverlay to loop
through the markers and remove them, but it is the same error when I
use clearOverlay too (I've left the call to map.clearOverlays();
commented out where it was)

I ran checks to make sure the markers were actually added to the map
(checking the markers pane property and it not being null == it has
added to the map?)

Not sure how this is possible if the markers are added to a pane, and
the pane is added to the map?

Any help/pointers welcome, cheers.






--~--~---------~--~----~------------~-------~--~----~
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 google-maps-api-for-flash@googlegroups.com
To unsubscribe from this group, send email to 
google-maps-api-for-flash+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-maps-api-for-flash?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to