Thomas Sampson

XML Parsing

Leave a comment

Today i started work on a desktop cleaning / sorting application called DeskTidy. I realised that I wanted to store a list of user defined filters for automatically tidying the desktop (based on filesize, type, age etc etc). The best way to store such information seems to be an XML document, so after research I found this document showing how to read an XML document from inside C# .NET, making use of the XMLTextReader object.

http://www.codeproject.com/csharp/csreadXml1.asp

This should come in handy for anyone wanting to read an XML document from C#. The object loops through nodes inside the xml and picks out variables. I think it can also cache and parse remote XML files from a URL (anyone making yet another rss reader?), not something I have tried though. In addition to the XMLReader object, the object XMLWriter exists to do pretty much the opposite. Here is some msdn documentation for the class

MSDN Article

Hope this is useful!

Advertisements

Author: tomtech999

I have recently graduated with a 1st class degree in MComp Games Software Development at Sheffield Hallam University, focusing primarily on application development in C++, with experience in graphics programming, scripting languages, DVCS/VCS and web technology. In my spare time I enjoy Drumming, Reading and Snowboarding!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s