Notices
Computer & Technology Related Post here for help and discussion of computing and related technology. Internet, TVs, phones, consoles, computers, tablets and any other gadgets.

XML C++/DOM problems....

Thread Tools
 
Search this Thread
 
Old Apr 29, 2003 | 02:10 AM
  #1  
BoxerFlat4's Avatar
BoxerFlat4
Thread Starter
Scooby Regular
 
Joined: Nov 2001
Posts: 923
Likes: 0
From: N Wales
Question

Anybody online used the XML DOM model, preferably in C++ before ? Having trouble accessing information from a DOMElement, i.e.

<ScoobyNet>It's A Scorcher!</ScoobyNet>

I can get access to it's "Name" part of the DOMNode(ScoobyNet), but can't seem to get to the "It's A Scorcher" value anywhere : it's not in the Value part of the DOMNode.

Anybody ? I suspect it's probably staring at me in the face....

[Edited by BoxerFlat4 - 4/29/2003 2:11:02 AM]
Reply
Old Apr 29, 2003 | 10:24 AM
  #2  
BoxerFlat4's Avatar
BoxerFlat4
Thread Starter
Scooby Regular
 
Joined: Nov 2001
Posts: 923
Likes: 0
From: N Wales
Post

Bounce for the morning....
Reply
Old Apr 29, 2003 | 11:45 AM
  #3  
TopBanana's Avatar
TopBanana
Scooby Regular
 
Joined: Jan 2001
Posts: 9,781
Likes: 0
Post

InnerText

Edit - actually I think it might just have been 'Text' in the COM version

[Edited by jlanng - 4/29/2003 11:47:19 AM]
Reply
Old Apr 29, 2003 | 11:48 AM
  #4  
Dizzy's Avatar
Dizzy
Scooby Regular
 
Joined: May 2001
Posts: 2,537
Likes: 0
Cool

IIRC isn't there a "dump" feature that will tell you the attributes? alough I suspect Jlang has it
Reply
Old Apr 29, 2003 | 01:19 PM
  #5  
BoxerFlat4's Avatar
BoxerFlat4
Thread Starter
Scooby Regular
 
Joined: Nov 2001
Posts: 923
Likes: 0
From: N Wales
Post

Thanks guys...

Found the problem, was using a DOMTreeWalker to process the document, and it wasn't behaving as I expected. Turned out I was filtering out all nodes EXCEPT element nodes, which meant I never had access to the relevant text in the first place.

Reply
Related Topics
Thread
Thread Starter
Forum
Replies
Last Post
warrenm2
Non Scooby Related
87
Mar 27, 2005 04:07 PM
warrenm2
Non Scooby Related
14
Feb 11, 2005 08:06 PM
David_Wallis
Computer & Technology Related
3
Oct 21, 2004 11:27 AM




All times are GMT +1. The time now is 04:29 PM.