-
XML - beginner
Hello,
I am an absolute beginner in XML.
My present desire to look at XML, is because I am tired of parsing text files.
I was wondering where I need to start looking if I wish to use XML for file creation and parsing, so that I can transfer data between a dll and a client.
Essentially the dll executes, processes and outputs an xml file, that the client then parses and uses that information.
Any help would be deeply appreciated.
thanks
pvarkey
-
XML-beginner
Have a look at msdn it gives a thorough insight into the matter
-
The first thing you should do is to take a look on the System.Xml namespace. This namespace contains all the classes you need.
Then start to use the XmlDocument.
Here is some code to get you started:
Code:
XmlDocument xmlDoc = new XmlDocument();
string xmlStuff = @"<root><child><![CDATA[Some text]]></child></root>";
xmlDoc.LoadXml(xmlStuff);
XmlNode node = xmlDoc.SelectSingleNode("root/child");
MessageBox.Show(node.InnerText);
Good luck!
GAT