Hi, im just loading a simple one line of xml into a dynamic textbox(nested in a movieclip).
but nothing appears there however:
1. if i put the textbox on the stage it works
2. i have adopted code from an already working dyunamic text box which is nested inside 2 movieclips.
3. i have applied a trace and that gives me the right result
so i am at a loss...
here is my code i am using:
PHP Code:
var xmlLoader:URLLoader = new URLLoader();
var xmlData:XML = new XML();
//askPage.nameA.condenseWhite = true;
btn1.addEventListener(MouseEvent.CLICK, beginXML);
function beginXML(event:MouseEvent):void {
xmlLoader.load(new URLRequest("askStudent.xml"));
xmlLoader.addEventListener(Event.COMPLETE, LoadXML);
}
function LoadXML(e:Event):void {
xmlData = new XML(e.target.data);
ParseBooks(xmlData);
//mapContainer.insideMap.library.removeEventListener(MouseEvent.CLICK, test);
}
function ParseBooks(askStudent:XML):void {
var Student1:XMLList = askStudent.student.(@studentName == "Dave");
trace(Student1.name)
askPage.nameA.htmlText = Student1.name;
}
thanks