Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 743815
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T08:54:25+00:00 2026-05-14T08:54:25+00:00

I’m having a problem retrieving a XMLList and I don’t understand why. I have

  • 0

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>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T08:54:25+00:00Added an answer on May 14, 2026 at 8:54 am

    In this line of code :

    var node:XMLList = storeData.stores.(@name==HomePageData.instance.divisionName).store.(odeis == HomePageData.instance.storeCodeOdeis)
    

    you are looking for the name attribute of the stores node. Which doesn’t appear in your XML example. You are likely filtering all of your results before you even move into the store child node.

    If this is not your problem, please post a more robust example of your storeData xml variable.


    I copy/pasted and made almost no changes to your E4X query and had no issue. This runs just fine:

    <?xml version="1.0"?>
    <!-- Simple example to demonstrate the ComboBox control. -->
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" creationComplete="init()">
        <mx:Script>
            <![CDATA[
                public var storeData:XML = new 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>
                );
    
                public function init():void{
                    trace(storeData.stores.(@name=="Japan").store.(odeis == "031"));    
                }           
    
            ]]>
        </mx:Script>
    </mx:Application>
    

    As far as I can tell you don’t have any problem that should result in that error. Are you sure that the error is coming from there and not some other line of code?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a French site that I want to parse, but am running into
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have just tried to save a simple *.rtf file with some websites and
this is what i have right now Drawing an RSS feed into the php,
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I ran into a problem. Wrote the following code snippet: teksti = teksti.Trim() teksti
Seemingly simple, but I cannot find anything relevant on the web. What is the
Does anyone know how can I replace this 2 symbol below from the string
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
I want to count how many characters a certain string has in PHP, but

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.