So i have a graphics layer (gLayer)when i draw a polygon onto graphics layer, it works okwhen i then select to draw a second, the first point i draw i get the following errorRangeError: Error #2006: The supplied index is out of bounds.
at flash.display::DisplayObjectContainer/addChildAt()
at mx.core::UIComponent/http://www.adobe.com/2006/flex/mx/internal::$addChildAt()
at mx.core::UIComponent/addChildAt()
at com.esri.ags.layers::GraphicsLayer/collectionAddHandler()
at com.esri.ags.layers::GraphicsLayer/collectionChangeHandler()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.collections::ListCollectionView/dispatchEvent()
at mx.collections::ListCollectionView/addItemsToView()
at mx.collections::ListCollectionView/listChangeHandler()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.collections::ArrayList/internalDispatchEvent()
at mx.collections::ArrayList/addItemAt()
at mx.collections::ListCollectionView/addItemAt()
at mx.collections::ListCollectionView/addItem()
at com.esri.ags.layers::GraphicsLayer/add()
at com.esri.ags.tools::DrawTool/addGraphic()
at com.esri.ags.tools::DrawTool/map_clickFirstHandler()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()
at com.esri.ags::Map/dispatchMapMouseEvent()
at com.esri.ags::Map/mouseUpHandler()
BUT, if i do gLayer.clear()
before hand it works okany ideas?