0 Replies Latest reply on Jul 6, 2007 6:52 PM by vivian hu

    Tree question: How to send the tree node id when I select it

    vivian hu Novice

      I used the following, and it always sends the last node's id to me. no matter which node I selected.

       <rich:tree style="width:300px"
       value="#{desktopBean.templateRoot}"
       var="item" nodeFace="leaf">
       <rich:treeNode type="leaf"
       onselected="saveFolderSelection();">
       <a4j:jsFunction name="saveFolderSelection">
       <a4j:actionparam name="folderPath"
       value="#{item.id}"
       assignTo="#{desktopBean.folderPath}"
       noEscape="false"/>
       </a4j:jsFunction>
       <h:outputText value="#{item.name}"/>
       </rich:treeNode>
       </rich:tree>