FindByViewCriteria API comes to the rescue...
BigDecimal value= new BigDecimal(100);
ViewObjectImpl myVO = getMyViewObjectVO1();
ViewCriteria vc = myVO.getViewCriteria("findByVC");
vc.ensureVariableManager().setVariableValue("MyId1",value);
RowIterator
byViewCriteria = myVO.findByViewCriteria(vc,
1,siteRef.QUERY_MODE_SCAN_VIEW_ROWS);
if(byViewCriteria.hasNext()){
Row row = byViewCriteria.next();
oracleCustomerId=(BigDecimal)row.getAttribute("OrderTotal");
}
See the documentation http://docs.oracle.com/cd/E15523_01/apirefs.1111/e10653/oracle/jbo/RowIterator.html
hi..
ReplyDeletei have readonly viewobject with transient attributes but i want with select checkbox apply viewcriteria and then filter viewobject but with unselect checkbox execute viewobject without filtering but keep data entered by user in transient attribute...
please help me...