Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 2794

How to Pass data of Odata Services to Simpleform Element in SAPUI5

$
0
0

Hi All,

 

i am beginner in SAPUI5 , i am writing complete code in index.html file only till now .

 

below is my code where i am trying to pass data to simpleform element

 

var oModel =

  new sap.ui.model.odata.ODataModel("http://abc.com:8002/sap/opu/odata/SAP/ZGET_SINGLE_DATA_SRV/",

  true,

  'p_usrid, 'p_pass');

 

 

  oModel.read("/empinfoSet('910302')");

 

 

var oSimpleForm = new sap.ui.layout.form.SimpleForm(

  "sf1",

  {

  maxContainerCols: 2,

  editable: true,

  content:[

  new sap.ui.core.Title({text:"Person"}),

  new sap.ui.commons.Label({text:"Name"}),

  new sap.ui.commons.TextField({value:"{Pernr}"}),

]

});

 

oSimpleForm.setModel(oModel);

oSimpleForm.placeAt("content");

 

 

Please Help..


Viewing all articles
Browse latest Browse all 2794

Trending Articles