How to set a bean property before executing this f:event listener
- by user
How to set a bean property from jsf page before executing this f:event listener:
<f:event type="preRenderComponent" listener="bean.method}"/>
I tried the below code but it does not set the value to the bean property.
<f:event type="preRenderComponent" listener="bean.method}">
<f:setPropertyActionListener target="#{bean.howMany}" value="2"/>
</f:event>
JSF2.1.6 with PF 3.3
EDIT
Any issues with this below code? (This works! but I just want to confirm if there are any issues with this!?)
<f:event type="preRenderComponent" listener="#{bean.setHowMany(15)}"/>
<f:event type="preRenderComponent" listener="#{bean.method}"/>