all groups > flash (macromedia) > december 2006 >
You're in the

flash (macromedia)

group:

need help with loadXML


need help with loadXML mita981
12/29/2006 10:31:30 PM
flash (macromedia):
i need help loading xml files. i have done some javascript codes that lets user
select from drop down lists and the end result would send an xml file name to a
text box to flash. in flash i have a dynamic text box which uses setVariable to
receive data from javascript. now all of this works just fine. the file name
shows up on my swf file. what i want to do is to load that xml file that the
text box receives. the xml file is a playlist so i use this code

myDisplay.loadXML(myText.text);

but nothing happens. the xml just doesn't load. now if try putting the xml
file name directly there like this

myDisplay.loadXML("playlist.xml");

it works fine. what i am thinking is that somehow my swf needs to get
refreshed or something like that. i am really lost on how i am supposed to go
about doing it. i have been looking on google for help but haven't really found
anything useful.

Re: need help with loadXML Scott Johnson
12/31/2006 9:04:25 PM
I myself have just started learning XML integration in flash, so I may
be wrong but here goes.

I have not seen and object with the 'loadXML' method, I have used the
'load' method as such.

trace("File coming from textbox: "+myText.text);
myDisplay = new XML();
myDisplay.load(myText.text);
myDisplay.onLoad = function(){
trace("Status: "+myDisplay.status);
}

Hope this helps, if not come back we will find a cure.
Scotty

[quoted text, click to view]
Re: need help with loadXML mita981
12/31/2006 9:29:30 PM
AddThis Social Bookmark Button