Hi list,
The following puzzles me:

//code in frame 1
1 var xmlData:xml;
2 trace(typeof(xmlData));                                       //'object' not 
xml??

//mijnXml.getHetXmlObject() is a method of a custom class that is supposed to return an xml-object
//code that loads the xml is ommitted
3 trace(typeof(mijnXml.getHetXmlObject()));     //'object' not xml??
4 xmlData = mijnXml.getHetXmlObject();

//called from a button I have the following:
6 trace(typeof(mijnXml.getHetXmlObject()));     //'xml'
7 trace(typeof(xmlData));                                       //'object' ???


My questions:
Why does flash see 'xmlData' as an object in line 2 although I specifically type it as 'xml' in line 1?

I understand that in line 3 somehow flash has not yet determined the type of the variable (not yet fully loaded?). Only after a while it 'sees' the correct type (line 6). Is that correct?

From Moock's EAS3 (p30) I understand that, as the type of the original variable (returned by mijnXml.getHetXmlObject()) is an object (line 3), xmlData holds only a _reference_ to the original variable. Thus, when the original variable changed to type 'xml', xmlData should also become type 'xml'. But according to line 7 it is still an object.
Why??
Thanks,
Willem van den Goorbergh



=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=
Geografiek is a Dutch, Utrecht-based map and chart design company.
Willem van den Goorbergh can be contacted by telephone: (+31) 30-2719512 or cell phone: (+31)6-26372378
or by fax: (+31)302719687
snail mail: Hooghiemstraplein 89 3514 AX UTRECHT
Visit our website at: http://www.geografiek.nl
=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=


_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to