Monday, April 7, 2014

Get the view object instance from the iterator in the backing bean in ADF?

import oracle.adf.model.BindingContext;
import oracle.adf.model.binding.DCBindingContainer;
import oracle.adf.model.binding.DCIteratorBinding;


BindingContext bindingContext = BindingContext.getCurrent();
DCBindingContainer dcBindings = (DCBindingContainer)bindingContext.getCurrentBindingsEntry() ;
DCIteratorBinding iterator = dcBindings.findIteratorBinding("EmployeesView1Iterator");
ViewObject vo = iterator.getViewObject();
  
Number empId =(Number)iterator.getCurrentRow().getAttribute("EmployeeId");

No comments:

Post a Comment