Hi!
I have an XML-Model over an ltap-table.
How do I get the fields out of an XML-Model?
The easiest way would be if I would be able to just write:
oData.ltap[0].tanum
but it doesn´t work.
So how can I do it?
Here is my sourcecode:
var oModel = new sap.ui.model.xml.XMLModel();
jQuery(function($) {
var oParameters = {
h_app_methode : "TEST123",
};
oModel.loadData("sapui5_seite.xml", oParameters, false, 'POST');
sap.ui.getCore().setModel(oModel);
oModel.updateBindings(true);
var oData = oModel.getObject("/asx:values/TABLE");
and here is the output of sapui5_seite.xml:
<?xml version="1.0" encoding="utf-16"?>
<asx:abap
xmlns:asx="http://www.sap.com/abapxml" version="1.0">
<asx:values>
<TABLE>
<LTAP>
...
<TANUM>0000000001</TANUM>
...
</LTAP>
<LTAP>
...
<TANUM>0000000002</TANUM>
...
</LTAP>
</TABLE>
</asx:values>
</asx:abap>