3 Replies Latest reply on May 22, 2011 4:11 AM by Coen Damen

    how to pass a parameter to a ModalPanel

    Coen Damen Novice

      Hi,


      I have a ModalPanel that I want to populate based on a product ID. I have the following code to call the ModalPanel.



      <a:commandLink value="ProductDetails22" oncomplete="#{rich:component('mp')}.show()"
           action="#{prodSelCon.setProductId(product.id)}">
           <a:actionparam name="productId" value="#{product.id}"assignTo="#{prodSelCon.productId}" />
      </a:commandLink>



      I can't get the value of the parameter to work because the ModalPanel is rendered before the parameter productId is even set, so it is always 0! As seen, I have tried it with onComplete(), onClick , an actionParam etc. Nothing works, so far.


      How can this be done? Thanks for your help,
      Coenos