0 Replies Latest reply on Jul 7, 2011 12:07 PM by Manas Sharma

    Problem calling <a4j:jsFunction>

    Manas Sharma Newbie


           This is regarding calling an <a4j:jsFunction>.

           We are building a web application with JSF 2.0 , rich faces 4.0 with Facelets. The problem is that we are trying to call an <a4j:jsFunction>  on click of an <h:commandLink>.On click of this comandLink we call a javascript which calls this <a4j:jsFunction>.But the call does not go into the java layer on first click of this commandLink but it goes on second click wherein lies the problem.This is just one of the instances whereas we are facing this problem as this is replicable when we click on <a4j:commandButton> too.The <a4:jsFunction> or <a4j:commandButton> are inside <a4j:region>.


           the code snippet:the xhtml code




                          <h:commandLink onclick = "callJavascriptFunc1();"/>

                          <a4:jsFunction id = "test" name = "test" actionListener = "#{testClass.openDetails}/>





      Please suggest some pointers.

      Thanks in Advance.