Hi,
I'm a newbie here.
I was wondering if someone can help me on how to do this:
I have a xml file, in which I need to get a all tags from a specific node, in less code.
Example:
<Root> <Hello1> <Hello2> <World>1</World> <World>2</World> <World>3</World> <World>4 <Help1>1</Help1> <Help1>2</Help1> <Help1>3</Help1> <Help1>4</Help1> </World> </Hello2> </Hello1> <Nihao1> </Nihao1> </Root>
Get all tags from Node "Hello2" <Hello2> <World>1</World> <World>2</World> <World>3</World> <World>4 <Help1>1</Help1> <Help1>2</Help1> <Help1>3</Help1> <Help1>4</Help1> </World> </Hello2>
Thanks for the help. Mhelinx
I got the answer from the previous questions.
Maybe this will help others.
https://sourceforge.net/forum/message.php?msg_id=2761156
TiXmlString s; TiXmlOutStream os_stream;
os_stream << * node; s = os_stream; return s; }
Regards, Rommel
Log in to post a comment.
Hi,
I'm a newbie here.
I was wondering if someone can help me on how to do this:
I have a xml file, in which I need to get a all tags from a specific node, in less code.
Example:
<Root>
<Hello1>
<Hello2>
<World>1</World>
<World>2</World>
<World>3</World>
<World>4
<Help1>1</Help1>
<Help1>2</Help1>
<Help1>3</Help1>
<Help1>4</Help1>
</World>
</Hello2>
</Hello1>
<Nihao1>
</Nihao1>
</Root>
Get all tags from Node "Hello2"
<Hello2>
<World>1</World>
<World>2</World>
<World>3</World>
<World>4
<Help1>1</Help1>
<Help1>2</Help1>
<Help1>3</Help1>
<Help1>4</Help1>
</World>
</Hello2>
Thanks for the help.
Mhelinx
Hi,
I got the answer from the previous questions.
Maybe this will help others.
https://sourceforge.net/forum/message.php?msg_id=2761156
TiXmlString s;
TiXmlOutStream os_stream;
os_stream << * node;
s = os_stream;
return s;
}
Regards,
Rommel