Hello Group,
I am new here and seeking help from you.
I have created a function in my Flex application and would like to use the HTTPService object from retreiving XML data from my webservice (based on PHP).
All the examples I have seen on the Adobe website use same approach (that I don't like) of binding the object to some controls.
What I trying to achieve is: Create an HTTP object, instruct that object to retreive a web XML string, store that string locally in a variable.
Using the code I have provided below, the application gives an error saying that the object is not yet created (null). And if I watch the task bar after the error message (in Firefox), I see that the flash application is accessing the webXML.
What might be wrong?
 
 
 
private function SampleFunction():void
{
 var http:HTTPService;
 var myXML:String;
 
 http = new HTTPService();
 http.url = ""http://www.domain.com/my_xml.php">http://www.domain.com/my_xml.php";
 http.method="POST";
 http.useProxy = false;
 http.showBusyCursor = true;
 http.resultFormat = "text";
 http.send();
 
myXML = http.lastResult.toString();
 
// Do something with XML

}
__._,_.___

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





SPONSORED LINKS
Web site design development Computer software development Software design and development
Macromedia flex Software development best practice


YAHOO! GROUPS LINKS




__,_._,___

Reply via email to