[Gambas-user] Xml Problem/?Bug?
Rory Verleysen
notorious at ...606...
Sun May 18 13:26:44 CEST 2008
Hi
I'm trying to write a simple rss parser and running in to some problems.
I'm running debian with gambas 2.5.0
rss file used is from news.yahoo.com
-
Reading the file: all goes fine
DIM xmlDoc AS XmlDocument
xmldoc = NEW XmlDocument
xmldoc.Open(strFileName)
-
reading topnode: all goes fine
eg: if xmldoc.root.name = "rss" then ...
-
assigning to seperate node: all goes fine
Dim xmlNod as XmlNode
xmlNod = xmldoc.Root
IF xmlNod.Name = "rss" THEN
-
xmldoc.root.value returns whole file contents (without <tags>)
-
reading or assigning a childnode: doesn't work <<<<<------------
DIM xmlNod as XmlNode
FOR i = 0 TO xmldoc.Root.Children.Count - 1
xmlNod = xmldoc.Root.Children[i]
PRINT Message.Info(xmlNod.Name)
'OR
PRINT Message.Info(xmldoc.Root.Children[i].Name)
NEXT
the above throws an "invalid object" error
Could someone please inform what i'm doing wrong?
Thanks in advance
Notorious
More information about the User
mailing list