Hi, I'm pretty unfamiliar with XML, but I'm writing a VBA program in excel that uses the MSN Soap Library to retrieve XML object's from this database on the web. Then I need to extract info from these XML objects and distribute them into a worksheet. Basically, the first part of my code returns an IXMLDOMSelection object, let's call it objX.
objX has a bunch of child nodes containing the info I want to extract. I'm trying to use the method 'getElementsByTagName(Name As String)' to return nodes matching a particular tagname so that I can get the text from those nodes and put it in the correct place in my worksheet. The problem is, I can't get "getElementsByTagName" to work properly. I searched the internet, and found out that the following command should return all nodes in the object, which it does.
objX.getElementsByTagName("*")
So when I look at the tagnames of these nodes and if, for example, the tagname of the 1st node is 'tag', the following command should return just that first node.
objX.getElementsByTagName("tag")
However, this is not returning anything at all, and I'm completely baffled as to how to make it work.
Hopefully someone has some idea of what I'm talking about and can either help me out or tell me I'm going about this the wrong way. Thanks
Bookmarks