I am trying to display nodes of a XML table into a Datagrid. As far as I have understand, I
put the nodes into the variable aRecords, and then, end of the loop, I put the variable aRecords
with dgData into the DataGrid.
I tried the code below, but no result will be shown in the DataGrid.
Code: Select all
private function readPreferencesToXMLTree
put url("URLTO/getallexhibdata.php") into tXML
put revXMLCreateTree(tXML, false, true, false) into tXMLTreeID
put revXMLRootNode(tXMLTreeID) into tRoot -- "messen"
put revXMLFirstChild(tXMLTreeID,tRoot) into tResponse -- "messe"
repeat while "xmlerr" is not in tResponse
put revXMLNodeContents(tXMLTreeID, tResponse & "/id") into tID
put revXMLNodeContents(tXMLTreeID, tResponse & "/messe_1") into aRecords[tID]["messe_1"]
put revXMLNextSibling(tXMLTreeID,tResponse) into tResponse
if tResponse is empty then
exit repeat
end if
end repeat
set the dgData of group "DataGrid" to aRecords
end readPreferencesToXMLTree
All the best, Stefan