I have code here that works correctly:
<h:selectOneMenu value="#{customer.selectedname}" id="ulist">
<f:selectItems value="#{customer.allCustomers}"/>
<f:ajax event="change" render="cid fname lname email sd" listener="#{customer.fullInfo}"/>
</h:selectOneMenu>
But, when I implement it in different project, it is not working. below is the code:
<td><h:outputLabel value="No Polisi:"/></td>
<td><h:inputText value="#{motor.VNOPOL}" id="VNOPOL"/></td>
<f:ajax event="valueChange" render="VIDPROSPEK VFRAMENUM VENGINENUM VTHNPROD NKMSERVICE " listener="#{motor.fullInfo}"/>
I got an error:
/index.xhtml @30,146 'valueChange' is not a supported event for HtmlForm. Please specify one of these supported event names: click, dblclick, keydown, keypress, keyup, mousedown, mousemove, mouseout, mouseover, mouseup.
What should I implement to show all info after my input in VNOPOL ?
JSF ajax supports only for JSF components, you have not enclosed <f:ajax> inside the component
you should change your code as below
<td>
<h:inputText value="#{motor.VNOPOL}" id="VNOPOL">
<f:ajax event="your event" render="your elements" listener="your listener"/>
</h:inputText>
</td>
Note that the <f:ajax> now inside <h:inputText>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With