Query within an xml document

Discussion in 'XML' started by vinuhyd, Sep 21, 2006.

  1. vinuhyd

    vinuhyd Guest

    I have an XML document in my asp.net application containing country
    information
    eg
    <Country>
    <CNo>1</CNo>
    <Country>Afghanistan</Country>
    <Nationality>Afghan</Nationality>
    <ISDCode>93</ISDCode>
    <Continent>Asia</Continent>
    </Country>
    <Country>
    <CNo>2</CNo>
    <Country>Albania</Country>
    <Nationality>Albanian</Nationality>
    <ISDCode>355</ISDCode>
    <Continent>Europe</Continent>
    </Country>
    <Country>
    <CNo>3</CNo>
    <Country>Algeria</Country>
    <Nationality>Algerian</Nationality>
    <ISDCode>213</ISDCode>
    <Continent>Africa</Continent>
    </Country>

    When a country is selected from a dropdown list, I want to be able to
    run through the xml document and pick out the corresponding continent
    only. What is the best way to do this?

    How can I do it using XMLTextReader....

    Thanks, Vinu
     
    vinuhyd, Sep 21, 2006
    #1
    1. Advertising

  2. vinuhyd

    Peter Flynn Guest

    vinuhyd wrote:
    [...]
    > How can I do it using XMLTextReader....


    You will get a better response if you post this in a Microsoft
    newsgroup like microsoft.public.dotnet.xml instead, as it relates
    to their software rather than directly to XML.

    ///Peter
    --
    XML FAQ: http://xml.silmaril.ie/
     
    Peter Flynn, Sep 21, 2006
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Tony Prichard
    Replies:
    0
    Views:
    756
    Tony Prichard
    Dec 12, 2003
  2. Manish Hatwalne
    Replies:
    1
    Views:
    406
    Martin Honnen
    Jul 13, 2004
  3. Replies:
    4
    Views:
    691
  4. Ultrus
    Replies:
    3
    Views:
    390
    Stefan Behnel
    Jul 9, 2007
  5. icogs
    Replies:
    0
    Views:
    149
    icogs
    Jan 31, 2008
Loading...

Share This Page