Ok im goin to reply to my own question....
<?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" creationComplete="initApp()" xmlns:net="flash.net.*"> <mx:Script> <![CDATA[ import flash.sampler.NewObjectSample; import mx.controls.Alert; private function initApp():void{ urlLdr.load(new URLRequest("../dataxml/ data2.xml")); } private function urlLdr_complete(evt:Event):void { var xmlData:XML = new XML(URLLoader (evt.currentTarget).data); //Alert.show(xmlData.toXMLString()); //Alert.show(xmlData.descendants('*').length().toString ()); // Alert.show(xmlData.body.length().toString()); var str:String= xmlData.toXMLString(); var myExp:RegExp = /<body>/ig; var numOftag:Array = str.match(myExp); Alert.show(numOftag.length.toString()); } ]]> </mx:Script> <net:URLLoader id="urlLdr" complete="urlLdr_complete(event);" /> </mx:Application> any suggestions???? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Flex India Community" 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/flex_india?hl=en -~----------~----~----~----~------~----~------~--~---

