public static MethodExpression getMethodExpression( String expr, Class returnType, Class[] argTypes){ FacesContext fc = FacesContext.getCurrentInstance(); ELContext elctx = fc.getELContext(); ExpressionFactory elFactory = fc.getApplication().getExpressionFactory(); return elFactory.createMethodExpression( elctx, expr, returnType, argTypes); } public static javax.faces.el.MethodBinding getMethodBinding( String expr, Class[] argTypes){ FacesContext fc = FacesContext.getCurrentInstance(); ELContext elctx = fc.getELContext(); return fc.getApplication().createMethodBinding(expr, argTypes); } SetPropertyListener listener = new SetPropertyListener( ActionEvent.class.getName()); listener.setFrom(link.getRoute()); listener.setValueExpression("to", JSFUtils.getValueExpression("#{pageFlowScope.route}", String.class)); action.addActionListener(listener); AdfFacesContext.getCurrentInstance().getPageFlowScope() .put("route", lin...
Hi Could you please elaborate on the example.
ReplyDeletei have a similar requirement where i have to make the first row as default when the table is populated by the query panel.
i do not know where to place this code.
Please help
I usually do this on the queryListener in the af:query. Have you tried a displayRow="first" on you table it may be simpler depending on your requirement.
Deletecan i use:
ReplyDeleteObject rowKey = resultTable.getScrollTopRowKey();
instead of:
Object rowKey = resultTable.getAttributes().get("scrollTopRowKey");?
I want the first row in my manageBean
ReplyDelete