×

Discussion Board

Results 1 to 5 of 5
  1. #1
    Registered User
    Join Date
    Mar 2012
    Posts
    4

    How to extract the xml data to listbox source?

    please refer the content updated above
    Last edited by gopi09_m; 2012-04-27 at 03:20.

  2. #2
    Registered User
    Join Date
    Mar 2012
    Posts
    4

    Re: How to extract the xml data to listbox source?

    Hi

    I have the following xml which i want to extract and put them in three list boxes.
    First listbox (TrasnPortService) should by default loaded with root items like SonyTransport,247Transport etc.
    When user selects SonyTransport from the list box TransportService i want to display the user the second listbox(Cities) with the name of the cities like Hyderabad,Chennai etc..
    When user selects a particular city (let's say Hyderabad ) then another list box( Locations ) will have all the locations of that city displayed as list items.

    Can anybody help me with some sample code on how to achieve this.Any help would be greatly appreciated.


    <SonyTransport>
    <City>
    <Hyderabad>
    <Location>AmeerPet</Location>
    <Location>AmberPet</Location>
    <Location>BeerumGuda</Location>
    <Location>ChandaNagar</Location>
    <Location>DilsukhNagar</Location>
    <Location>Erragadda</Location>
    <Location>Falakhnuma</Location>
    <Location>GayatriNagar</Location>
    <Location>IndiraNagar</Location>
    <Location>JubileeHills</Location>
    </Hyderabad>
    <Chennai>
    <Location>AnnaNagar</Location>
    <Location>BataNagar</Location>
    <Location>ChennaiNagar</Location>
    <Location>DolaNagar</Location>
    <Location>EnnaNagar</Location>
    <Location>FanimojiNagar</Location>
    <Location>KanimojiNagar</Location>
    </Chennai>
    </City>
    </SonyTransport>

    <247Transport>
    <City>
    <Hyderabad>
    <Location>AmeerPet</Location>
    <Location>AmberPet</Location>
    <Location>BeerumGuda</Location>
    <Location>ChandaNagar</Location>
    <Location>DilsukhNagar</Location>
    <Location>Erragadda</Location>
    <Location>Falakhnuma</Location>
    <Location>GayatriNagar</Location>
    <Location>IndiraNagar</Location>
    <Location>JubileeHills</Location>
    </Hyderabad>
    <Chennai>
    <Location>AnnaNagar</Location>
    <Location>BataNagar</Location>
    <Location>ChennaiNagar</Location>
    <Location>DolaNagar</Location>
    <Location>EnnaNagar</Location>
    <Location>FanimojiNagar</Location>
    <Location>KanimojiNagar</Location>
    </Chennai>
    </City>
    </247Transport>

  3. #3
    Nokia Developer Champion
    Join Date
    Feb 2009
    Location
    India
    Posts
    1,173

    Re: How to extract the xml data to listbox source?

    Please check this article for XML Parsing.

  4. #4
    Nokia Developer Champion
    Join Date
    Aug 2008
    Location
    Vadodara, India.
    Posts
    911

    Re: How to extract the xml data to listbox source?

    you can get more help on this tutorial.
    http://www.windowsphonegeek.com/tips...nd-databinding
    Nokia Developer Wiki Moderation team
    World's Greatest Speeches for Windows Phone is now available on WP Marketplace.

  5. #5
    Registered User
    Join Date
    Dec 2011
    Location
    Tampa Bay, FL
    Posts
    3

    Re: How to extract the xml data to listbox source?

    Is someone generating that XML or did you write it up as a sample?
    The reason I ask is its malformed.
    You can't have an xmlelement started with a number.
    Also the syntax isn't name attribute friendly, nor is there a root node.
    Too a stab at it but its not well formed enough to push along.

Similar Threads

  1. How to extract html data
    By nithyakrishnan in forum Symbian
    Replies: 1
    Last Post: 2009-07-18, 11:43
  2. How to extract Data from OnContentL( )
    By prabhupingili in forum Symbian
    Replies: 5
    Last Post: 2007-11-01, 10:19
  3. Extract data from application into sms
    By szj2003 in forum General Messaging
    Replies: 4
    Last Post: 2007-05-01, 21:42
  4. I need to extract sms inbox data by midlet
    By farhanx in forum Mobile Java Tools & SDKs
    Replies: 1
    Last Post: 2006-10-01, 20:05
  5. Replies: 2
    Last Post: 2004-07-08, 09:36

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×