Read/ Update/ write XML using Dataset()

Discussion in 'XML' started by saudakhan@gmail.com, Feb 28, 2006.

  1. Guest

    Hi,
    I have a wierd XML file

    <Ins>
    <HomeP>
    <RqUID>SomeRqUID1</RqUID>
    <Trans>2006-02-17</Trans>
    <HomeL>
    <LOB>HOME</LOB>
    <Producer>
    <ProducerInfo>
    <ContractNumber>3098048</ContractNumber>
    </ProducerInfo>
    <ItemIdInfo>
    <A>123456</A>
    </ItemIdInfo>
    <GeneralP>
    <NameInfo>
    <CommlName>
    <CommercialName>Agent Name</CommercialName>
    </CommlName>
    </NameInfo>
    <Addr>
    <AddrTypeCd>MailingAddress</AddrTypeCd>
    <Addr1>690 A Ave</Addr1>
    <City>City</City>
    <StateProvCd>CT</StateProvCd>
    <PostalCode>06115</PostalCode>
    </Addr>
    </GeneralP>
    </Producer>
    </HomeL>
    </HomeP>
    </Ins>

    As you can see, I cant figure ou how many tbles I am supposed to asume,
    or read a first. I need to daisplay this Document on a form, and the
    Update it with new values uing A DataSet.
    I can read tables like
    foreach(DataRow dr in XmlDs.Tables["HomeP"].Rows)
    {
    Response.Write("0 ele of "+tname+"= "+dr[0]+"<br>");
    }

    But how do I get to know wether there is a table later or a row?
    and XmlDs.Tables["HomeP"].Rows.Count;

    gives me 1 ????
    How do I go about here?
    plz help
    , Feb 28, 2006
    #1
    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. Replies:
    0
    Views:
    428
  2. Armando
    Replies:
    1
    Views:
    10,292
    Bill Seurer
    Apr 27, 2004
  3. Replies:
    0
    Views:
    420
  4. ringo
    Replies:
    0
    Views:
    161
    ringo
    Aug 18, 2004
  5. EmJayEm
    Replies:
    0
    Views:
    108
    EmJayEm
    Jan 20, 2005
Loading...

Share This Page