1 Reply Latest reply on Sep 24, 2009 5:12 AM by Ilya Shaikovsky

    a4j:support call not firing on selectBooleanCheckbox after o

    Manoj Goel Newbie

      Hi All,

      I have code like this:

      <a4j:repeat value="#{taxProgram.selectedItems}" var="selectItem" rowKeyVar="itemIndx">



      <h:panelGrid >
      <h:selectBooleanCheckbox value="#{selectItem}" >
      <a4j:support event="onclick" immediate="true" ajaxSingle="true"
      reRender="buttons,msgregReqd"
      action="#{eregBusinessVetting.toggleSelectedTaxProgram(taxProgram,itemIndx,!selectItem,eregBusinessVetting.getRandomNumber())}"
      />
      </h:selectBooleanCheckbox>
      </h:panelGrid>



      </a4j:repeat>


      This checkbox when clicked once it fires the action code but second and subsequent clicks does not fire action method. I have wasted 2 days to figure out why it is not working. Only reason I can think is ajax request is not fired due to internal caching or it sees nothing has chnaged in the call so why fire again.

      How can I solve this issue?

      My intent is to toggle the yes/no response from user and set some business logic so that we can dynamically set some buttons to hit 'next' button. If all checkboxes are unselected I want the button to disappear(which I am able to do) but when I click the checkbox again it should fire the event calling action to set some stuff so that 'Next' button appears again.

      Please help

      Thanks

      Manoj