Yes, that is about the structure of the XML.
Well I tried implementing what you described in your previous posts, but I'm getting an error thrown, see asterisks in the code below:
/tmp/plugin/HGAAAAhOIGYV/pkg:/source/main.brs(85): runtime error ec: 'Dot' Operator attempted with invalid BrightScript Component or interface reference.
085: If xmlFileCount <> invalid And FileCountString.Count() > 0 Then
If I leave out all the testing and use this:
FileCountString=xml.GetNamedElements("file-count")[0].GetText()
it works just fine. The code:
xfer.setURL(api+resource+user+uresource+ckey)
xferResult = xfer.GetToString()
print "transfer-result"+xferResult
'ok, now we have the user info, we need the number of files that user has
if xml.Parse(xferResult)
'from user info get number of Files
xmlFileCount = xml.GetNamedElements("file-count")
****** If xmlFileCount <> invalid And FileCountString.Count() > 0 Then
FileCountString = xmlFileCount[0].GetText()
End If
print FileCountString
FileCountNumeric=val(FileCountString)
print FileCountNumeric
print type(FileCountNumeric)
end if
End Sub
Screenshades: The first Screensaver for Roku2!
Musiclouds: The best free internet music, on your Roku!
Ouroborialis: Psychedelic Screensaver for Roku!