If we take the following example from the ExtractXMLArray() documentation it will work fine:
Code: Select all
Xml$ = "<array><element>1</element><element>10</element><element>100</element></array>"
If ParseXML(0, Xml$) And XMLStatus(0) = #PB_XML_Success
Dim MyArray(0) ; will be resized by the next call
ExtractXMLArray(MainXMLNode(0), MyArray())
For i = 0 To ArraySize(MyArray())
Debug MyArray(i)
Next i
Else
Debug XMLError(0)
EndIf
Therefore, we can't use ExtractXMLArray() for XML structures using a different tag name for it's array elements.
ExtractXMLElement() should provide an additional parameter allowing the developer to define the tag name to use for searching for the child element. Or even better: Simply use all direct child elements independently of the name.