Tutorial on XML namespaces?

J

Jon Davis

I would like to parse RSS 1.0 (not RSS 2.0) files. But I don't know how to
work with these XML namespaces! And when namespaces are improperly used in
RSS 2.0 files, I don't know how to deal with them and exceptions keep
getting thrown! Does anyone have a tutorial or know of one that deals with
XML namespaces with the .NET framework, preferably in C#, or maybe a good
book to read? I just got my hands on Applied XML Programming for Microsoft
..NET, but it does NOT properly distinguish XML namespaces and how to work
with them.

Thanks for any help.

Jon
 
G

Guest

I was in the same situation about 4 months ago. I needed to suddenly know a lot about XML and XML schemas. I went out and bought 2 books. "XML Complete" (Sybex) $19.99 & "The XML Schema companion" (Addison Wesley) $39.99

It took me thereafter a couple of days to realise that namespaces in XML are merely unique identifiers and actually DON'T exist in reality

The nearest analogy I can think of now is the same elements and attributes in two different XML namespaces can be regarded similarly to the same method and property names of two different objects without a common interface

crater
 
O

Oleg Tkachenko [MVP]

Jon said:
I would like to parse RSS 1.0 (not RSS 2.0) files. But I don't know how to
work with these XML namespaces! And when namespaces are improperly used in
RSS 2.0 files, I don't know how to deal with them and exceptions keep
getting thrown! Does anyone have a tutorial or know of one that deals with
XML namespaces with the .NET framework, preferably in C#, or maybe a good
book to read? I just got my hands on Applied XML Programming for Microsoft
.NET, but it does NOT properly distinguish XML namespaces and how to work
with them.

First get strong understanding of namespaces -
http://www.jclark.com/xml/xmlns.htm.
Then take a look at "XML Namespaces and How They Affect XPath and XSLT"
at
http://msdn.microsoft.com/library/en-us/dnexxml/html/xml05202002.asp?frame=true
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top