Skip to Content
0
Apr 16, 2014 at 06:57 AM

Update the selected data to the oData

67 Views

Hi Everyone,

I am trying to apply the CRUD function from the below document,

Building a CRUD Application with SAPUI5 Using Odata Model .

Create operation is working fine but during Update I am unable to read the data from the table which is displayed in the UI. It is showing the below error msg,

And below is the code of that portion,

var oTable = sap.ui.getCore().getElementById('ID_EmployeeListTable');

var i = oTable.getSelectedIndex();

if (i==-1){

alert("Please Select a row to Update");

return;

}

else if(i>=0){

var selectedRow = oTable.getRows()[i];

var selectedId = selectedRow.getCells()[0].getValue(); (in this line the error is coming in the func getValue())

Kindly tell me how to read the data from the UI table to update the data in the backend?

Regards,

Soumya

Attachments

Capture3.JPG (121.1 kB)