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

Re: retrieve bindingcontext from list and standardlistitem

$
0
0

Hi lahari,

 

1. You have to set a model to the control which has an aggregation associated with it. So in your case it should be sap.m.List

 

2. You can use either of the events to get the binding context (i.e you can get the bindingcontext from list events as well as standardlistitem events)


3.1 .Get BindingContext from list events

for example in select event you have to use oevent.getParameter("listItem").getBindingContext()

 

here is the api doc JsDoc Report - SAP UI development Toolkit for HTML5 - API Reference - sap.m.ListBase

 

 

You can refer the example provided by sai for getting the bindingcontext from list events

 

 

3.2 Get BindingContext from StandardListItem events

 

For example in press event you have to use oevent.getSource().getBindingContext()

here is an example.


JS Bin - Collaborative JavaScript Debugging




Viewing all articles
Browse latest Browse all 3132

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>