Hi,
I've saved an Excel spreadsheet to XML using Excel 2003 and now want
to read it using VB.net
Below, I've pasted an abbreviated snippet from the XML file. The
actual file is really long, but this section should demonstrate my
problem. I am trying to read this file using VB.net and find the
Worksheet node using the following code:
Dim xmlDocument As new XmlDocument
xmlDocument.Load(sFileName)
Dim aNode As XmlNode = xmlDocument.SelectSingleNode("//Workbook")
I've tried several different XPath syntaxes and I've also tried
looking for different nodes. I can't seem to get anything, even though
the code works when I test it with a simpler XML file not generated by
Excel.
Can anyone help me retrieve and navigate XML nodes in this Excel
generated XML file please?
Thanks for any help.
xmlns:x="urn:schemas-microsoft-com:office:excel"
xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet"
xmlns:html="http://www.w3.org/TR/REC-html40">
x:FullColumns="1"
x:FullRows="1">
2008/03/31
For Answers, see/post comments
Problem Reading Excel XML Options
Subscribe to:
Post Comments (Atom)
1 comment:
I would look at this:
http://blog.stevex.net/index.php/xpath-and-xml-namespaces/
Hope this helps (it helped me)
~Lee
Post a Comment