I have a basic question. I am loading an XML file using the URLLoader and putting it into an XML variable.
My question is, can i leverage E4x to go through this xml data.
I tried doing
for each (var grid in xmlData.grid){
output.text=grid.name;
}
But it says that variable ‘grid’ has no type declaration. This might make some sense since there is no way for the compiler to know before hand the structure of the XML that i am loading.
But since i am new to AS3 and flex, i was wondering if there is a way of leveraging E4x?
Thanks
You could type it anonymously (it would solve the problem):
but before you do that, consider these options here:
If you use one of those judiciously, it will probably be closer to what you’re looking for.