4 Replies Latest reply on May 23, 2008 4:37 AM by sad bouf

    static tree

    sad bouf Newbie

      would create a satatic tree :
      my jsf :
      <rich:panel style="height: 100%; width:100%; background-color: #CAC7B7">

      <rich:tree style="width:200px" styleClass="align-center-margin" mode="ajax" itemClass="white"
      hoveredItemClass="blue">
      <rich:treeNode label="artist" iconLeaf="/images/tree/singer.gif" icon="/images/tree/singer.gif">
      <f:param name="current" value="Company1"/>
      </rich:treeNode>
      <rich:treeNode label="album" iconLeaf="/images/tree/disc.gif" icon="/images/tree/disc.gif">
      <f:param name="current" value="Company2"/>
      </rich:treeNode>
      <rich:treeNode label="song" iconLeaf="/images/tree/song.gif" icon="/images/tree/song.gif">
      <f:param name="current" value="Company3"/>
      </rich:treeNode>
      </rich:tree>
      </rich:panel>



      the error is :

      org.richfaces.component.EnclosingFormRequiredException: class org.richfaces.component.html.HtmlTree (id="j_id96") did not find parent form. org.richfaces.component.util.FormUtil.throwEnclFormReqExceptionIfNeed(FormUtil.java:45)
      org.richfaces.renderkit.html.TreeRe

        • 1. Re: static tree
          Florian Marwede Expert

          ...hmm...and where is your parent form?

          • 2. Re: static tree
            sad bouf Newbie

            yes i forget to put the form tag
            but i have an other error:
            java.lang.ClassCastException: com.sun.facelets.StateWriter
            com.sun.faces.renderkit.html_basic.HtmlResponseWriter.endElement(HtmlResponseWriter.java:300)
            org.richfaces.renderkit.html.TreeRenderer.doEncodeEnd(TreeRenderer.java:251)
            org.richfaces.renderkit.html.TreeRenderer.doEncodeEnd(TreeRenderer.java:259)
            org.ajax4jsf.renderkit.RendererBase.encodeEnd(RendererBase.java:135)
            javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:829)
            org.ajax4jsf.renderkit.RendererBase.renderChild(RendererBase.java:286)
            org.ajax4jsf.renderkit.RendererBase.renderChildren(RendererBase.java:262)
            org.richfaces.renderkit.html.PanelRenderer.doEncodeChildren(PanelRenderer.java:220)
            org.richfaces.renderkit.html.PanelRenderer.doEncodeChildren(PanelRenderer.java:215)
            org.ajax4jsf.renderkit.RendererBase.encodeChildren(RendererBase.java:121)
            javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:810)
            javax.faces.component.UIComponent.encodeAll(UIComponent.java:884)
            javax.faces.render.Renderer.encodeChildren(Renderer.java:137)
            javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:810)
            javax.faces.component.UIComponent.encodeAll(UIComponent.java:884)
            javax.faces.component.UIComponent.encodeAll(UIComponent.java:890)
            com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:571)
            javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:178)
            org.ajax4jsf.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:108)
            org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:189)
            com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:106)
            com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:248)
            com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:144)
            javax.faces.webapp.FacesServlet.service(FacesServlet.java:245)
            org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:147)
            org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:256)
            org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:362)
            org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:488)
            org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:147)
            org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

            • 3. Re: static tree
              sad bouf Newbie

              i found the solution for this error, i must to update my JSF to 1.2_04
              but when i excute my page it display no thing !!!!!

              please help it s urgent

              • 4. Re: static tree
                sad bouf Newbie

                no help ?!
                please it s so urgent