I have the following code:
private var xmlC:XMLListCollection = new XMLListCollection();
private var httpS:HTTPService = new HTTPService();
private var timer:Timer = new Timer(1000);
private var xmlData:XML;
private var xmlDataList:XMLList;
protected function application1_creationCompleteHandler(event:FlexEvent):void
{
httpS.url = "data.xml";
httpS.addEventListener(ResultEvent.RESULT, resultHTTP);
httpS.resultFormat="e4x";
httpS.send();
timer.start();
timer.addEventListener(TimerEvent.TIMER, updateXMLC);
}
private function updateXMLC(event:TimerEvent):void
{
xmlC.source = xmlDataList;
httpS.send();
}
private function resultHTTP(event:ResultEvent):void
{
xmlData = event.result as XML;
xmlDataList = xmlData.dg.rows.row;
}
"data.xml" have 5000 lines, so I need to clean its traces whenever necessary. I have two problems that I found thanks to the profiling
Seems it was a bug in Flex framework: