ADF Faces menuTree component example

I am new to faces technology and I would appreciate if someone can give or point me to a demo creating and managing ADF faces menuTree component. How to dynamically create menus from SQL?
Regards, Simon

Hello,
an example of an ADF Faces Tree component you can find in SRDemoSample. It's used in SRManage.jspx
hope it helps you a bit, MenuTree should work similar.
Cheers, Stefan

Similar Messages

  • Unable to implement Programmatic ADF Faces Tree component in jdev 11g

    I have referred to the posts " [Back to programming: Programmatic ADF Faces Tree component|http://one-size-doesnt-fit-all.blogspot.com/2007/05/back-to-programming-programmatic-adf.html] " and " [Follow-up: Programmatic ADF Faces Tree in JDev 11g|http://one-size-doesnt-fit-all.blogspot.com/2007/05/follow-up-programmatic-adf-faces-tree.html] ",
    The first post showed how to construct the elements in the tree programmatically rather than relying on bindings (in JDeveloper 10.1.3)
    and the second post tells the only difference in 11g .
    I am trying to implement the elements of the tree programatically in Jdev 11g(specifically 11.1.1.0.2) but no result is coming .
    There is no compilation/run time error , its just that the tree is not visible.
    Can anyone suggest any key points which should be focussed during this implementation?

    Hi,
    follow the description
    http://www.oracle.com/technology/products/adf/adffaces/11/doc/demo/adf_faces_rc_demo.html
    to install the ADF Faces RC component demo in JDeveloper. It has a tree example. Have a look at their implementation and dapt it to your needs
    Frank

  • JDeveloper 11.1.2.3, ADF Faces: declarative component does not support af:clientListener?

    I am trying to create a declarative component with the following code:
    <?xml version='1.0' encoding='UTF-8'?>
    <af:componentDef xmlns:af="http://xmlns.oracle.com/adf/faces/rich" var="attrs" componentVar="comp" definition="private"
                     xmlns:afc="http://xmlns.oracle.com/adf/faces/rich/component">
        <af:xmlContent>
            <afc:component>
                <afc:display-name>DoubleClickTableDialogClientServerListener</afc:display-name>
                <afc:component-extension>
                    <afc:component-tag-namespace>org.mskcc.crdb.common.declarativecomponent</afc:component-tag-namespace>
                    <afc:component-taglib-uri>http://www.mskcc.org</afc:component-taglib-uri>
                </afc:component-extension>
            </afc:component>
                <af:clientAttribute name="serverListenerType" value="TableDoubleClickEvent"/>
                <af:clientListener method="handleTableDoubleClick" type="dblClick"/>
                <af:serverListener type="TableDoubleClickEvent"
                                   method="#{EditAddDialogTemplateBean.handleTableDoubleClick}"/>
        </af:xmlContent>
    </af:componentDef>
    At runtime I recieve the following error:
    javax.faces.view.facelets.FaceletException: ADF_FACES-60023:Component: DoubleClickTableDialogClientServerListenerComponent[oracle.adf.view.rich.component.fragment.UIXInclude$ContextualFacesBeanWrapper@7170a7, id=dctdcsl1] does not support client listeners.
      at oracle.adfinternal.view.faces.facelets.rich.BaseClientListenerHandler.apply(BaseClientListenerHandler.java:53)
    This component was intended to be dropped off within an af:table component. I would like to hear suggestions on workarounds, one other way I thought about was to create a code template for the three tags, however, the con to this approach is each developer would need to configure this template within jdeveloper. Ideas are appreciated.
    Also a side question, how can I embed code properly with the new forum? [code] tag does not seem to work now.

    Wes, can't help with the real question, but can tell you how to format code
    Change to the advanced editor (top right over the editor field), then you get more options. The one you are looking for is behind the blue '>>'. Here you select the language you want to insert and you get nice code formatting and color.
    Timo

  • How to add adf faces in component pallete of jdeveloper 11g?

    how to add adf faces in component pallete of jdeveloper 11g?

    Hi,
    the replacement of ADF Faces HTML components in JDeveloper 11 is Trinidad. For existing applications, a migration path will be provided in JDeveloper 11 production. I wouldn't recommend configuring ADF Faces in JDeveloper 11.
    You an configure ADF Faces Components in JDeveloper 11 by :
    - Tools --> Manage Libraries
    - Create a User Library
    - select ADF Faces adf-faces-impl.jar
    - Enure the namespace is not af or afh but something different to not cnflic with teh ADF Faces RC components
    Note that adding the ADF Faces components to the component palette will not make them show in the ADF binding context menu nor will it automaticaly set up the web.xml file. The components are available as any other JSF library set
    Again, I wouldn't go this way ;-)
    Frank

  • TP 2 generates unknown ADF Faces RC component

    JHeadstart 11g TP 2 generates an unknown ADF Faces RC component af:inputHidden when the Display Type of an item is set to Hidden in de JHS application definition.
    fragment from generated jsff:
    <af:inputHidden id="UserPreferencesuprfDummy" value="uprfDummy"/>
    fragment from default/item/form/formHiddenField.vm:
    <af:inputHidden #ITEM_ID_IN_FORM() #ITEM_VALUE_IN_FORM()/>
    Furthermore, when inspecting the used template via JHS Application Definition Editor, I find that the FORM_HIDDEN_FIELD entry is listed 2 times under the Forms Items category.
    Hope this feedback helps in wrapping up the production version of the promising 11g release.
    (JDeveloper 11g build 5407, JHeadstart 11g TP2 build 46).
    Regards,
    Eric

    For further info and in case it helps with the debugging, we're finding that a JHS item defined as Display Type=hidden will generate this Trinidad tag in the JSFF file. tr:inputHidden No hidden fields are generated in the JSPX file.
    As a workarond, we're changing these items to Display Type = textInput and Display in Form Layout and Display in Table Layout = "false." That generates an inputText item in the JSPX (not JSFF) file.
    Peter

  • ADF Faces + accordion component

    Hi all,
    Has anyone out there used any 3rd party "accordion" component with ADF Faces? Examples of one's that I've found but not tried:
    Google Web Toolkit (GWT) StackPanel widget - might be hard to integrate with JSF
    MyFaces accordionPanel - pretty nice, but it's still in the "sandbox" project
    IceFaces has an in-development accordion - IceFaces doesn't play nice with ADF Faces components on the same page due to a special renderer
    Spry Accordion from Adobe - similar comments to GWT.
    Some examples of what I mean:
    The Mail/Tasks/Contacts item here: http://code.google.com/webtoolkit/documentation/examples/desktopclone/demo.html
    http://archive.dojotoolkit.org/nightly/tests/widget/test_AccordionContainer.html
    http://www.irian.at/myfaces-sandbox/accordionPanel.jsf
    The closest thing in ADF Faces is the af:showOnePanel, which is pretty close, but not exactly what I'm looking for. Perhaps with some skinning, I could get it to look different (no +/- in the little triangle, etc). An update... thanks to BUG 5682799, we are not able to get rid of the little hide/disclose (+/-) widget - the skin selector for that item is ignored.
    Thanks for any insight.
    John

    Hi John,
    Bug 5682799 has been fixed in JDeveloper 10.1.3.3
    If you need a one-off patch for a prior release of JDev, please contact Support.
    Regards,
    Didier.

  • Compare between component id in adf faces and component id in html.

    Hi all,
    [Oracle ADF Faces 11g]
    When I design layout and set ID for ADF Component such as:
    <af:inputText id="*itCalendar*" />
    After I run and view HTML source, I saw:
    <INPUT class=x25 id=*j_id_id7:itCalendar* name=*j_id_id7:itCalendar*/>
    My question:
    1. Why ID changed after I run ?
    2. How to away: ID don't change ?
    3. Why all atributes of Javascript attributes in adf faces 11 don't show? such as:
    onchange
    onclick
    ...etc.,
    Can you help me, please?
    thanks all.

    User,
    1). The ID changes because your af:inputText is inside another component that is a naming container. the *j_id_id7 is the (apparently auto-generated) ID used by the naming container.
    2). Don't put your component inside of a naming container (tongue-in-cheek, as that's usually not very possible). The best thing is to put ID's on all of your components, then you can know what the final ID in the HTML will be
    John

  • How do I create multiple types of child nodes in ADF  Faces Tree Component

    Hi,
    I am trying to construct a tree using ADF Faces. The tree I am trying to develop should look something like:
    - Departments
    + Dept 10
    + Dept 20
    + Dept 30
    + Dept 40
    - Employees
    + SCOTT
    +ALLEN
    + BLAKE
    The nodes shown at the top level should serve as labels, indicating the various types of nodes available.
    I have created the top level RootLabelsViewObj, with a SQL clause:
    select rn, node_label
    from (
    select 1 rn
    , 'Employees' node_label
    from dual
    union all
    select 2 rn
    , 'Departments' node_label
    from dual
    union all
    select 3 rn
    , 'Bonusplans' node_label
    from dual
    I have created ViewLinks between the RootLabelsViewObj and the DeptView and EmpView respectively (created on top of DEPT and EMP table in SCOTT schema), based on the LABEL attribute in the RootLabelsViewObj and with ViewLink SQL specified like:
    :Bind_NodeLabel = 'Departments' for the link with DeptView and :Bind_NodeLabel = 'Employees' for the link with EmpView.
    In the ADF BC Application Module Tester, I get exactly what I want.
    However, when I create a JSF JSPX page and drag the RootLabelsViewObj from the Data Control Panel to the page as ADF Tree, I run into a little issue: it seems like I cannot create a second Branch Accessor rule for the RootLabelsViewObj1: I have created a first Branch Accessor Rule referring to DeptView and now try to create a second one for EmpView, to allow Employees to be displayed under the root label "Employees" - but I cannot.
    The PageDefinition looks like:
    <tree id="RootLabelsViewObj1" IterBinding="RootLabelsViewObj1Iterator">
    <AttrNames>
    <Item Value="Rn"/>
    <Item Value="NodeLabel"/>
    </AttrNames>
    <nodeDefinition DefName="model.RootLabelsViewObj"
    id="RootLabelsViewObjNode">
    <AttrNames>
    <Item Value="NodeLabel"/>
    </AttrNames>
    <Accessors>
    <Item Value="DeptView"/>
    </Accessors>
    </nodeDefinition>
    <nodeDefinition DefName="model.EmpView" id="EmpViewNode">
    <AttrNames>
    <Item Value="Ename"/>
    </AttrNames>
    </nodeDefinition>
    <nodeDefinition DefName="model.DeptView" id="DeptViewNode">
    <AttrNames>
    <Item Value="Deptno"/>
    </AttrNames>
    </nodeDefinition>
    </tree>
    Does anyone know:
    - whether it is possible (intended) to have more than one branch accessor per node (i.e. more than one type of child under a node in the tree)
    - if so, how this can be achieved?
    Right now it looks like I am limited to each node in the tree having only one type of child node.
    Please tell me I am wrong.
    best regards,
    Lucas

    Give this a shot mate
    event.getNativeEventTarget();That will allow you to access the DOM object directly
    Id can be retrieved via
    event.getNativeEventTarget().id;

  • Initializing an ADF Faces selectManyListbox Component

    I am trying to show a selectManyListbox with some values already selected for an edit page, but all i get is a selectManyListbox with no values selected?
    I build the <af:selectManyListbox> using a <af:forEach> which iterates through a List of custom TermType objects creating a <af:selectItem> with each iteration <af:selectItem>'s value property is assigned to an actual object (the toString() method of the object has been overriden to return a simple id string) and the label property is set to label="#{termType.term_type_name}" which produces a String.
    I have set <af:selectManyListbox... valuePassThru="true" ... value="#{TermBean.selectedTermTypes}"...>
    I have configured the function ---> "TermBean.selectedTermTypes" to return a List of "TermType" custom objects and didn't work... return a List of Strings (that match the value sent through to the outputted web page) and finally to return a String[] matching the value property outputted, but no luck....
    when using plain old <h:selectManyListbox> i can get it displaying with selected items when setting the "value" property to String[] of selected items (the Strings match the outputted value) but of cource this dosn't render nicely with all the extras like the adf selectManyListbox.
    i have also tried to do the job in java code hence the "binding" attrib being set to binding="#{TermBean.selectManyTermTypes}"
    Here is the page section that creates the selectManyListbox...
    region_term.jspx
    <?xml version="1.0" encoding="iso-8859-1" standalone="yes" ?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="1.2" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" xmlns:afh="http://xmlns.oracle.com/adf/faces/EA17/html"
    xmlns:af="http://xmlns.oracle.com/adf/faces/EA17">
    <jsp:directive.page contentType="text/html;charset=utf-8"/>
    <af:regionDef var="region_term">
    <af:panelForm>
    <af:inputText label="#{bundle.TERM_NAME}:" value="#{TermBean.tempTerm.term_name}" required="#{region_term.required_term_name}"/>
    <af:selectManyListbox label="#{bundle.TERM_TYPE_S}:" required="#{region_term.required_term_type}" valuePassThru="true" binding="#{TermBean.selectManyTermTypes}" value="#{TermBean.selectedTermTypes}">
    <af:forEach var="termType" items="#{TermBean.allTermTypes}">
    <af:selectItem value="#{termType}" label="#{termType.term_type_name}"/>
    </af:forEach>
    </af:selectManyListbox>
    <af:inputText label="#{bundle.TERM_TEXT}:" value="#{TermBean.tempTerm.term_text}" required="#{region_term.required_term_text}" rows="6" columns="60"/>
    </af:panelForm>
    </af:regionDef>
    </jsp:root>
    <af:selectManyListbox label="#{bundle.TERM_TYPE_S}:" required="#{region_term.required_term_type}" valuePassThru="true" binding="#{TermBean.selectManyTermTypes}" value="#{TermBean.selectedTermTypes}">
    <af:forEach var="termType" items="#{TermBean.allTermTypes}">
    <af:selectItem value="#{termType}" label="#{termType.term_type_name}"/>
    </af:forEach>
    </af:selectManyListbox>
    TermBean.allTermTypes = a List of custom Term objects
    Can anybody tell me if they have managed to get a <af:selectManyListbox> with items already selected when the page loads?

    i realize valuePassThru is used for passing the value of your object or primitive through to the client... i have it off now and the problem isn't solved... the main issue is in the following:
    <af:selectManyListbox... value="#{TermBean.selectedTermTypes}">
    <af:forEach var="termType" items="#{TermBean.allTermTypes}">
    <af:selectItem value="#{termType}" label="#{termType.term_type_name}"/>
    </af:forEach>
    </af:selectManyListbox>
    if value="#{TermBean.selectedTermTypes}" is a List of "termType "objects (want these to be selected when the page loads) of the same type as var="termType" items="#{TermBean.allTermTypes}" i.e. getSelectedTermTypes() returns a List of objects of the type termType... why is the select box rendering with no selected items?

  • ADF faces PanelPage component

    I want to install this but I am unable to find the way.
    How can I install this?
    I used wizard to generate this welcome page:
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="1.2"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:af="http://xmlns.oracle.com/adf/faces"
    xmlns:afh="http://xmlns.oracle.com/adf/faces/html"
    xmlns:adfp="http://xmlns.oracle.com/adf/faces/portlet"
    xmlns:cust="http://xmlns.oracle.com/adf/faces/customizable">
    but then wizard left me in no man land. I have no idea which files to install, where and how? When I click JSP Tag libraries I do not see components like:
    ADF Faces Components
    ADF faces HTML
    Customizable Components Core

    Does anybody know what is the location of tag libraries referenced in this page?
    <?xml version='1.0' encoding='windows-1252'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="1.2"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:af="http://xmlns.oracle.com/adf/faces"
    xmlns:afh="http://xmlns.oracle.com/adf/faces/html"
    xmlns:adfp="http://xmlns.oracle.com/adf/faces/portlet"
    xmlns:cust="http://xmlns.oracle.com/adf/faces/customizable">
    <jsp:text>
    <![CDATA[ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> ]]>
    </jsp:text>
    <jsp:directive.page contentType="text/html;charset=windows-1252"/>
    <f:view>
    <html>
    <head>
    <meta http-equiv="Content-Type"
    content="text/html; charset=windows-1252"/>
    <title>Welcome</title>
    <link type="text/css" rel="stylesheet" href="css/jdeveloper.css"/>
    </head>
    <body><h:form></h:form></body>
    </html>
    </f:view>
    <!--oracle-jdev-comment:auto-binding-backing-bean-name:backing_WEBINF_pages_Welcome-->
    </jsp:root>

  • ADF Faces - Find component

    Hi everyone,
    I need to find a component by its id in the view from the code in the bean. I have written the following method, but is working only when the way is straight, i mean
    view
    html
    head
    body
    form
    component
    component_to_be_found
    but not in the following case, or alikes:
    view
    html
    head
    body
    form
    component 1
    component 1.1
    component 1.2
    component_to_be_found
    component 2
    the method is as follows:
    public UIComponent getElementById(UIComponent base, String compId) {
    Dummy.println("Base = " + base);
    if (compId.equals(base.getId())) {
    Dummy.println("Encontrado = " + base);
    return base;
    UIComponent component = null;
    ArrayList<UIComponent> list = (ArrayList<UIComponent>) base.getChildren();
    for (UIComponent component2 : list) {
    if ((component = getElementById(component2, compId)) != null) {
         return component;
    return null;
    any help is mostly welcome,
    ip

    package com.groundside.view.security.listener;
    import java.util.Iterator;
    import javax.faces.component.UIComponent;
    import javax.faces.context.FacesContext;
    public class JSFHelper {
        public JSFHelper() {
         * Locate an UIComponent in view root with its component id. Use a recursive way to achieve this.
         * Taken from http://www.jroller.com/page/mert?entry=how_to_find_a_uicomponent
         * @param id UIComponent id
         * @return UIComponent object
        public static UIComponent findComponentInRoot(String id) {
            UIComponent component = null;
            FacesContext facesContext = FacesContext.getCurrentInstance();
            if (facesContext != null) {
                UIComponent root = facesContext.getViewRoot();
                component = findComponent(root, id);
            return component;
         * Locate an UIComponent from its root component.
         * Taken from http://www.jroller.com/page/mert?entry=how_to_find_a_uicomponent
         * @param base root Component (parent)
         * @param id UIComponent id
         * @return UIComponent object
        public static UIComponent findComponent(UIComponent base, String id)
            if (id.equals(base.getId()))
                return base;
            UIComponent children = null;
            UIComponent result = null;
            Iterator childrens = base.getFacetsAndChildren();
            while (childrens.hasNext() && (result == null)) {
                children = (UIComponent)childrens.next();
                if (id.equals(children.getId())) {
                    result = children;
                    break;
                result = findComponent(children, id);
                if (result != null) {
                    break;
            return result;
    }Frank

  • How to save the structure of a formatted text in adf faces output component

    Hi all
    please help me.
    I need to display my formatted text (with line breaks) in the jsf page. How can i do this. If i use OutputText all my line break ("\n") are ignored, the same effect with OutputFormatted component. I have tried to substitute linebreaks with the respective html tags but it also didn't take an effect.
    Thanks in advance

    Hi Timin,
    Set the Escape property on the outputText or the outputFormatted to <b>false</b>
    I believe only HTML tags will work though
    -chris

  • ADF Faces Declarative Component onLoad event call Backing Bean Method

    Hello.
    We are trying to implement a declarative component, that will be used as Flex Fields for our application, ie, the components will be created dynamically through a database configuration, and who is responsible for organizing and creating the components, is the declarative components, and its own backing bean.
    The declarative component, will receive a List of custom components, and with this list it is possible to create the components dynamically. We want the components to be created as soon as the page is loaded. The developer could place this declarative component in any region of his page, and even in another tab if he wishes. The problem is, that we cannot register a load event in the declarative component, since it doesn't have a document Object, to call the declarative components backing bean method that is responsible for creating components.
    How could we simulate the onLoad (of the declarative components) so that the backing bean method (responsible for creating component, and putting it in the view tree) could be called ?
    I've tried with a RENDER_RESPONSE phaseListener, but the beforePhase has no objects in the tree, and the afterPhase has already rendered to the client.
    Any ideas on how to achieve this ?
    Thanks a lot.
    Regards,
    John

    Hi Frank, thanks for the response.
    I'm curious about the dynamic declarative component. Any place I could check it out ?
    Back to my scenario. I'll try to be more clear to what we need!
    We have to have dynamic creation of components, based on a database configuration. This will allow our customers to have custom flex fields, without the need of us developing custom pages for each customer.
    One solution we are trying out, is the declarative component. Why ? Because the developer (when developing the page), knows that this specific page, is possible of customization by the client (custom flex fields). With this, the developer would choose where on his page the custom flex fields will be placed. Note that at this point (design time), no component (input, buttrons, etc) is created. The idea of the declarative component, is just so the Developer knows where he wants the custom fields placed in his page (a tab, below the form fields, in a another panel group, and so on). The declarative component, has only a container, PanelFormLayout, and no other component.
    What we want, is a way of calling our managed bean (the managed bean of the declarative component, that now I did configure it in the adfc-config.xml file , thanks for the tip) method, that's responsible for creating the custom components. The declarative component, receives a list of all the custom fields that needs to be created, at design time, through an attribute. The developer is responsible for setting this list when he drags the declarative component on his page.
    Now that I've put the declarative components managed bean in the adfc-config.xml file, the @PostConstruct is called correctly, but I still have a problem. At this moment (postContstruct call), my component PanelFormLayout (that is binded to the managed bean), is null. So I cannot add any component to the PanelFormLayout.
    Am I way out of line here Frank ?
    Really appreciate your comments.
    Thanks a lot.
    John

  • Region and regionDef not showing up in ADF Faces Core component palette.

    Any reason why? Everything else listed at: http://www.oracle.com/technology/products/jdev/htdocs/partners/addins/exchange/jsf/doc/tagdoc/core/imageIndex.html seems to be there (in the palette).
    Using JDev 10.1.3.0.4

    Go into project properties -> JSP libraries and make sure you add the data visualization tag library.

  • ADF Faces: Making a component non-navigable. How?

    Hi,
    Is it possible to make an ADF Faces component non-navigable? Something like specifying
    tabindex="-1"in HTML.
    I need this most for buttons.
    Best regards,
    Bisser

    That's right. JSF produces such IDs. They are causing problems with JAAS login forms, so we should use plain JSPs for login, but for the rest of the tasks such IDs are okay.
    What I meant is that currenty the buttons are not rendered as
    <input type="button" ... />but as pictures embedded in hyperlinks (&lt;a>).
    It's possible, though not likely, that in some future version of ADF Faces some component will be rendered as an HTML element that doesn't support tab ordering (although I haven't really considered if there are such elements). Then the trick with manually setting the tabIndex of the parent HTML element won't work.
    Of course, I deeply appreciate the fact that you take the time to help us on this forum. In fact, I will go ahead and do just that -- I will dynamically set the tabIndex via JavaScript. I was simply wanting to make sure that I wasn't taking such a hack-like approach, if there was a better method.
    Thank you again.
    Best regards,
    Bisser

Maybe you are looking for

  • How can I fix the remote control order of the chapters?

    I am using the new 6.0 theme of Reflection Black--submenu Chapters. THis gives you two rows of chapters (which shows the looping movies and title of the chapter). I am importing the .mov slideshows in the order I want them accessed with the remote co

  • TRYING TO DOWNLOAD ITUNES---NOT WORKING

    got my new 30gb ipod today. went to the apple web site to download itunes. I clicked on download & the screen shifted to the next screen which indicated it had downloaded. Nothing happens after that. No install wizzard or equivalent. Background....I

  • Can I find out what the New Features are for Updates?

    When the Application Manager says an Update is available, as far as I can see so far, it just says New Features.  Is there a web page that will give more details about what features etc. each update will provide?  The Application Manager is not showi

  • No company code data available in XD01

    Hi All, I'm facing a issue in XD01 transaction code. In my current client process of creation of customer is first Master data team is responsible for creation of  General data segment of the customer once general segment is created it comes to SD us

  • Turn off file validation setting office 2013

    Good evening, i'm trying to find how the Turn off file validation setting in excel 2013 from office h&b 2013 on a windows 7 home premium 64bit, but i can't find it anybody can help me? Thanks in advance Bye Filippo