Hello!
I'm having a problem retrieving a XMLList and I don't understand why.
I have an application that is running properly. It uses some data from two xml files called division.xml and store.xml. I noticed that I have some data in division.xml that should be in store.xml, so I did a copy/paste of the data from one file to the other. This is the data I copied:
<stores name="Japan" division="C300">
<store>
<odeis>101</odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
<store>
<odeis>102</odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
</stores>
In the application, I list all odeis codes and I need to retrieve the block store corresponding to the selected odeis code.
Before moving the data into store.xml, this is how I retrieved the block:
var node:XMLList = divisionData.division.(@name==HomePageData.instance.divisionName).stores.store.(odeis == HomePageData.instance.storeCodeOdeis)
This is how I retrieve it after copying the data into store.xml:
var node:XMLList = storeData.stores.(@name==HomePageData.instance.divisionName).store.(odeis == HomePageData.instance.storeCodeOdeis)
And I'm currently getting the following error:
ReferenceError: Error #1065: The variable odeis is not defined.
Could anyone enlighten me? Cause I really have no clue of why it is not working...
Thanks for any tips you can give.
Regards, BS_C3
Complete xml structure for division.xml and store.xml
division.xml:
<data>
<division name="Europe">
</division>
<division name="Japan">
<stores>
<store>
<odeis>101</odeis>
<name> </name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
<store>
<odeis>031</odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
<store>
<odeis>032</odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
</stores>
<fingerSize>
.
.
.
</fingerSize>
<clarities>
.
.
.
</clarities>
<colors>
.
.
.
</colors>
</division>
</data>
store.xml:
<data>
<stores name="Europe" division="C100">
<store>
<odeis></odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
<store>
<odeis></odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
<store>
<odeis></odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
</stores>
<stores name="Japan" division="C300">
<store>
<odeis>101</odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
<store>
<odeis>031</odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
<store>
<odeis>032</odeis>
<name></name>
<password></password>
<currency></currency>
<currSymbol></currSymbol>
</store>
</stores>
</data>