Hello Experts,
So here is the situation:
view 1
var SelectCondType = new sap.m.Select(
{
id : "SelectCondType",
width : "200px"
});
var oItemSelectTemplate1 = new sap.ui.core.Item({
key : "{ID}",
text : "{Name}"
});
var sServiceUrl = "blablabla.com:8000/sap/opu/odata/sap/YXM_GWS_BART_SRV";
var oModel = new sap.ui.model.odata.ODataModel(sServiceUrl, false,
"user", "pass");
SelectCondType.setModel(oModel);
SelectCondType.bindAggregation("items","/cond_type",oItemSelectTemplate1);
view 2
sap.ui.getCore().byId("SelectCondType").setSelectedKey(response.Condtype);
At the first view i have a sap.m.select which is already filled with id's and Name's.
And at the second view i wanna change the selecteditem of the sap.m.select so that it goes to
the item with the same key(id).
At the moment nothing happens. The selected item is just the one on top of the list.
Any Ideas?
Kind Regards,
Bart