Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

help for binding text in sap.m.text


I am trying to Bind text property of sap.m.Text but i am not successful.Please help me on this.

I am not getting any error in console same time not getting the output i.e names

var oModel = new sap.ui.model.json.JSONModel();

  var oData = [{name : "jagadeesh",surname : "biyyapu","count":1 },

              {name : "jagadeesh",surname : "biyyapu" ,"count":2}];


var soid1 = new sap.m.Text().bindText("{name}");


return soid1;

Former Member
Former Member replied

Hi Jagadeesh, you cannot bind an array data.. that is oData = [{}.{}..] directly in a Text control, for that you need put text control inside a list an use bindAggregation and templates for do that.

I show you two examples what may be help you : Example 1 and Example 2



0 View this answer in context

Helpful Answer

Not what you were looking for? View more on this topic or Ask a question