Hi guys,
I’m having a problem loading in XML to Flash via a .NET-powered web service. Basically, I can bring the following XML in:
<response>
<success>true</success>
<result xsi:type=“welcomeMessage”>
<body>Welcome to the website…</body>
</result>
<errors/>
</response>
I’m using the following AS to load it in…
public namespace type = “welcomeMessage”;
use namespace type;
public function handleLoadSuccessful($evt:Event):void
{
use namespace type;
resultVars = new URLVariables();
resultVars.decode($evt.target.data);
responseXML = XML($evt.target.data);
dispatchEvent(newStandardCustomEvent(WelcomeMessageService.ONMESSAGE_EVENT, responseXML));
}
I’m pretty sure it’s to do with the name space and I feel I should use the following line at the top of my class… public namespace xsi:type = “welcomeMessage”; but that’s not allowed. When my Flash catches the dispatch, it can trace out the “true” from the XML but just traces blank lines when it gets to the line with the “xsi:type” in it.
Does anybody have any ideas? Going a bit insane here!