Click here to Skip to main content
12,946,304 members (49,691 online)
Rate this:
 
Please Sign up or sign in to vote.
See more:
hi all,
i have xml file like this

<Item>
    <ID>1</ID>
    <ItemNo>100</ItemNo>
    <ItemName>Galaxsy Asc</ItemName>  
  </Item>

and another xml file like below
<Item>    
    <Id>2</Id>
    <No>2</No>  
    <Qty>3</Qty>
    <ItemId>1</ItemId>


i want to take
<Qty>3</Qty>
and add in in the first xml file to be like
<Item>
    <ID>1</ID>
    <ItemNo>100</ItemNo>
    <ItemName>Galaxsy Asc</ItemName> 
    <Qty>3</Qty> 
  </Item>


according to ItemId.
i have written a code but extracting the value of Qty itself "3" not the whole node .

can any one helps me in this please

thanks
Posted 6-Feb-13 22:49pm

1 solution

Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

  Permalink  
Comments
NNos2012 7-Feb-13 6:03am
   
the link you attach is about reading node value , as the result there is "Google Pacman" , but in want to have the node itself "<name>Google Pacman" to add it in another xml file not reading it.
thanks
manognya kota 7-Feb-13 6:29am
   
then you can try using importnode.

see the link,
http://blog.project-sierra.de/archives/1050

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

    Print Answers RSS
Top Experts
Last 24hrsThis month
OriginalGriff 4,919
CHill60 3,235
Maciej Los 2,508
Jochen Arndt 1,935
ppolymorphe 1,795


Advertise | Privacy | Mobile
Web02 | 2.8.170518.1 | Last Updated 7 Feb 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100