Add checkbox on the nodes of Hierarchical tree in oracle forms 9i

Hi,
I am working on oracle forms 9i.I have to add checkbox at the place of node(+/-) in Hierarchical tree so,
that user can select or deselect the Tree.That can do in oracle forms but how i don't know.
can anybody help me.....
Regards,
Hemant

You can't change this aspect of the Tree Control in Oracle Forms using built-in functionality. You might be able to extend the Tree Control using Java, but you have to do this yourself. : (
Craig...

Similar Messages

  • Make an hierarchical Tree in oracle Forms 6i

    Hi everybody,
    I want to make an hierarchical tree. I work in Forms 6i
    I create one non database block e.g. 'Bloc2' then
    add hierarchical control item in that. e.g 'Menu'.
    I create a record group named 'RG_DATA_TEST'
    Before I use a table in this record_group.
    I want a tree as this :
    - Menu1
    Menu1 option1
    Menu1 option2
    - Menu1 option3
    Menu option3 Sub opt 3
    + Menu2
    the table 'Menu_tree' is described' :
    CREATE TABLE MENU_tree
    ID NUMBER(5),
    LABEL VARCHAR2(128 BYTE),
    ICON VARCHAR2(40 BYTE),
    MASTER NUMBER(5),
    STATUS NUMBER(1) DEFAULT 1,
    VALUE VARCHAR2(128 BYTE)
    Here the data in the table :
    INSERT INTO MENU_tree ( ID, LABEL, ICON, MASTER, STATUS, VALUE ) VALUES (1, 'Menu1', 'mainmenu', NULL, 1, NULL);
    INSERT INTO MENU_tree ( ID, LABEL, ICON, MASTER, STATUS, VALUE ) VALUES (
    2, 'Menu1 Option 1', 'optionmenu', 1, 1, 'Dialog11');
    INSERT INTO MENU_tree ( ID, LABEL, ICON, MASTER, STATUS, VALUE ) VALUES ( 3, 'Menu1 Option 2', 'optionmenu', 1, 1, dialog12');
    INSERT INTO MENU_tree ( ID, LABEL, ICON, MASTER, STATUS, VALUE ) VALUES (4, 'Menu1 Option 3', 'optionmenu', 1, 1, NULL);
    INSERT INTO MENU_tree ( ID, LABEL, ICON, MASTER, STATUS, VALUE ) VALUES ( 5, 'Menu1 Opt 3 Sub Opt 3', 'suboptionmenu', 4, 1, 'Dialog131');
    INSERT INTO MENU_tree ( ID, LABEL, ICON, MASTER, STATUS, VALUE ) VALUES ( 6, 'Menu2', 'mainmenu', NULL, -1, NULL);
    INSERT INTO MENU_tree ( ID, LABEL, ICON, MASTER, STATUS, VALUE ) VALUES ( 7, 'Menu2 Option1', 'optionmenu', 6, 1,'Dialog21');
    The record_group use this instruction SELECT :
    SELECT STATUS, LEVEL, LABEL, ICON, VALUE
    FROM MENU_tree
    CONNECT BY PRIOR ID = MASTER
    START WITH MASTER IS NULL
    And At the trigger When_new_form_instance , i do this code :
    DECLARE
    htree ITEM;
    V_IGNORE number;
    BEGIN
    HTREE := FIND_ITEM('BLOC2.MENU');
    V_IGNORE := POPULATE_GROUP('RG_DATA_TEST');
    FTREE.POPULATE_TREE(htree);
    END;
    When i run the forms, It don't give me a structure of node.
    It give me only a icon with two arrows.
    Where is the problem ?
    Must I add code somewhere ?
    Help me for your ideas.
    Regards.
    Edited by: 794982 on 17 sept. 2010 04:55
    Edited by: 794982 on 17 sept. 2010 05:01
    Edited by: 794982 on 17 sept. 2010 05:04
    Edited by: 794982 on 17 sept. 2010 05:06
    Edited by: 794982 on 17 sept. 2010 05:13
    Edited by: 794982 on 17 sept. 2010 05:19
    Edited by: 794982 on 17 sept. 2010 05:23

    Ok Francois Thanks for your response.
    Just I pricise i work with oracle forms version 9.0.4.0.19 .
    But I am putting this code in trigger When_New_form_Instance but it didn't work.
    When I execute it just shows a line with two arrows but not a real tree.
    Then I do a block-non based and a elemnt with type hierarticall tree and a canevas.
    and i create a record_group. and in a palette property of the element i precise the canevas and the record_group
    I don't khnow where is the problem ?
    Any other suggestion ? please
    Regards.

  • Tooltip not visible on hierarchical tree in Oracle Forms 11g

    *Hi..  i have tried to set the "TOOLTIP" option for an hierarchical item during design time(property palatte) and also at run time( set_item_property).
    But still its not working!!!
    However it works for Oracle 10g forms.
    Is this some kind of restriction only in Oracle 11g forms for the hierarchical items? Please help!

    You can't change this aspect of the Tree Control in Oracle Forms using built-in functionality. You might be able to extend the Tree Control using Java, but you have to do this yourself. : (
    Craig...

  • ALV Tree - how to put checkbox on the node level?

    Hello everyone!
    I have an AlvTree and I have special column named SEL. That column contains checkboxes. I want to put additional checkboxes at the node level, I need them to create select all option.
    In other words I must somehow create something similar to do_sum option. DO_SUM works for numeric columns, the sum of all rows in current node appears at the top level. So I must do the same but checkbox.
    Are there any ideas?
    Here is my code of creating the tree.
    DATA: g_tree9001 type ref to cl_gui_alv_tree_simple.
    " Here I fill fieldcat...
    create object g_tree9001
          EXPORTING
            i_parent                    = g_doc_cont
            i_node_selection_mode       = cl_gui_column_tree=>node_sel_mode_single
            i_item_selection            = 'X'
            i_no_html_header            = 'X'
            i_no_toolbar                = ''.
    call method g_tree9001->set_table_for_first_display
          EXPORTING
            i_save              = 'A'
            is_variant          = ls_variant
          CHANGING
            it_sort             = gt_sort9001
            it_outtab           = gt_tree9001
            it_fieldcatalog     = gt_treefcat9001.
    My output table gt_tree9001 has sthe following structure:
    BUKRS, KTEXT, SEL, SWERK.
    My sort table gt_sort9001 has 2 rows. Sorting by BUKRS and KTEXT.
    My tree looks like this:
    BUKRS/KTEXT  --- SEL --- SWERK
    +bukrs1 ------------------------------
      -- ktext1 ---  X --- swerk1
      -- ktext2 ---  X --- swerk2
    +bukrs2 ------------------------------
      -- ktext3 ---  X --- swerk3
    I want to get:
    BUKRS/KTEXT  --- SEL --- SWERK
    +bukrs1 ----------X----------------
      -- ktext1 ---  X --- swerk1
      -- ktext2 ---  X --- swerk2
    +bukrs2 ----------X----------------
      -- ktext3 ---  X --- swerk3
    Appreciate any help!

    Hi ,
    Check the below threads, it may give some idea to get check box in the node .
    [LINK1|Check box on left navigation of ALV tree;
    [LINK2|Checkbox ALV Tree CL_GUI_ALV_TREE;
    Regards,
    Saravana.S

  • Problem when selecting child node in Hierarchical Tree

    I have a hierarchical tree on a form populated thru a table query(form1). When I click on a child node, it opens form2 which contains a tab canvas. After closing forms, I return to the form1(containing Tree). At this point If I want to click on the same child node, I should be able to open form2 again. This doesn't happen.
    I have the following code in my When-Tree-node_selected trigger:
    Declare
    htree item;
    vnode_label varchar2(50);
    node_clicked FTREE.NODE;
    vnode_value number;
    vnode_depth number;
    v_type number;
    v_value varchar2(100);
    v_form_name varchar2(100);
    v_alert_return number;
    begin
    -- Find the tree itself.
    htree := FIND_ITEM('tree_block.tree');
    node_clicked := :SYSTEM.TRIGGER_NODE;
    vnode_value := FTREE.NODE_label;
    -- Find the value of the node clicked on.
    vnode_label := FTREE.GET_TREE_NODE_PROPERTY (htree,:SYSTEM.TRIGGER_NODE,FTREE.NODE_label);
    vnode_depth := to_number(ftree.get_tree_node_property(htree,:SYSTEM.TRIGGER_NODE,ftree.Node_depth));
    --Open form for node selected on tree and/or specific tab page
    if vnode_depth <> 1 then
    if :system.trigger_node_selected = 'TRUE' then CASE vnode_label
    WHEN 'Personal' then
    v_form_name :='HR_PERSONAL_INFO_UPDATE';
    WHEN 'Citizenship' then
    v_form_name :='HR_PERSONAL_INFO_UPDATE';
    WHEN 'Emergency Contact' then
    v_form_name :='HR_PERSONAL_INFO_UPDATE';
    if id_null(Find_form(v_form_name)) then
    open_form(:global.application_path || v_form_name,ACTIVATE,NO_SESSION,SHARE_LIBRARY_DATA);
    else
    go_form(v_form_name);
    end if;
    END IF;
    elsif vnode_depth = 1 then
    if :system.trigger_node_SELECTED = 'TRUE' then CASE vnode_label
    WHEN 'EMPLOYEE INFO' then
    v_form_name :='HR_PERSONAL_INFO_UPDATE';
    vnode_label := 'Personal';
    WHEN 'REPORTS' then
    v_form_name :='HR_REPORTS';
    vnode_label := '';
    if id_null(Find_form(v_form_name)) then
    v_form_name := :global.application_path || v_form_name;
    open_form(v_form_name,ACTIVATE,NO_SESSION,SHARE_LIBRARY_DATA);--,p_list);
    else
    go_form(v_form_name);
    end if;
    end if;
    end;
    Can anyone please help me? I don't want the user to double click. They should only click once.
    Thanks,
    Mercedes

    Right clicking does not change the current selection. The tree has no way to report what node was right clicked. Only work around is to left click the node you wish then right click it.
    --pat                                                                                                                                                                                                                                                                                                                                                                                                       

  • Programmatic, using bean add Parent and child nodes in af:tree dynamically

    Hi All,
    i have to add parent and child nodes dynamically in tree .
    Example :
    i have created a tree like below.On click of button i will get value A ,from pl/sql function i will A1 and A 2 values.which i have to show in pop as tree.
    A
    |-----A1
    |-----A2
    If user clicks on A2.I have to catch A2 value and pass to pl/sql function which gives A2.01 and A2.02 values.
    A
    |-----A1
    |-----A2
    |------A2.01
    |------A2.02.
    A, A1 ,A2,A2.01 ...........values comes from pl/sql funchtion .
    thanks in advance ......... any suggestion will greatly helps

    no use ......................

  • How to not display nodes in a tree if Oracle roles are NOT used?

    How to not display nodes in a tree if Oracle roles are NOT used?
    We don't use Oracle DB roles to grant users access to Forms from the menu. We use a template and role system of our own. Basically a few tables with templates and roles.
    We want to convert our normal Forms menu to a tree menu and one of our key requirements is that when the tree is populated ONLY nodes with programs (i.e. forms) he has been granted to execute is shown.
    Since we don't use Oracle Roles how to do this in a tree?
    I created a function to show/hide LEAF nodes, BUT problem is that there are sub-menu nodes showing even if the leaf-nodes under it has not being displayed. My function has suppressed it.
    My tree query is like this:
    SELECT
         t.status, LEVEL, t.label, t.icon, t.node VALUE
    FROM
         tma_tree_menu t
    WHERE
    tma_authenticate_sys_chk_role(USER, t.node) = 1
    CONNECT BY
         PRIOR t.node = t.master
    START WITH
         t.MASTER IS NULL
    ORDER SIBLINGS BY
    t.position
    The tma_authenticate_sys_chk_role will return 1 only if the user has access to the form under that node.
    I tried the FTree functions in Forms but even that has nothing.
    Any help would be greatly appreciated.
    Edited by: Channa on Mar 17, 2010 6:49 AM

    Would you share the source code? I guess what I need is how exactly you retreive the user credentials from the DB table and set that boolean variable.
    and then how to condition it in UIX?

  • Hierarchical tree - Data Entry Form

    I am trying to make a data entry form for hierarchical tree. Any one help me to send a sample .fmb file.
    I created a table like
    create table master_ACTIVITY
    (INITIAL_LEVEL NUMBER (4) ,
    NODE_DEPTH NUMBER (4) ,
    NODE_LABEL VARCHAR2(160) ,
    NODE_ICON VARCHAR2(60) ,
    NODE_DATA VARCHAR2(160) ,
    NODE_PARENT VARCHAR2(160)
    1. How do i use hierarchical tree for adding and deleting item into it.
    2. In my other form i use the item from hierarchical tree. so how to get the return value of the selected item in a hierarchical tree. and which of filed in this table i need in other forms to connect to this table and get values.
    please send a sample form to [email protected]
    thank you
    saji daniel

    Andreas,
    It got worked.
    I have another problem now. I have 2000 records in my tree. when i populate it is taking time to populate.
    I want to display only parent trees ie Level 1 & 2 Items. But the Level 1 & 2 should have '+' symbol to display.
    When the user click on any items in level 2, only then the child of the selected parent should populate.
    By default all the items are displayed in collapsed mode (-1). But still it take time to populate.
    Any solution ?.

  • Hierarchical Field in Oracle Forms

    Hi Experts
    Can any one please give me a sample code to write a hierarchical field in Oracle Forms. I want to display
    Category->Organization->Item->Quantity
    Thanks in Advance.
    Ahmed

    okay,
    place your treeitem in the layout. The treeitem has to the only item in the block and property "Single record" has to be true.
    To populate your tree with data you can either
    - use a query to populate a treeitem have a look at this thread Tree Menu
    - use the Ftree.Add_Tree_Node built-in and program your own logic.

  • How to encrypt the text in password field in Oracle Forms version 6i

    Need help!
    How to encrypt the text in password field in Oracle Forms version 6i?
    one way is to change the settings in the property palette. Can somebody provide me some script to be run while the form is running which will enable the password to be encrypted?
    Thanks!

    Hello,
    Do you mean "hidden" (replaced with stars) or encrypted (that needs to be decrypted ?
    Francois

  • Hierarchy tree in oracle forms problem

    Hello Experts,
                         I am new in oracle forms.I am using oracle forms 11g with weblogic server 10.3.5 at windows 7.I have two table as tbl_country and tbl_state.I have to make a hierarchy tree in oracle forms.My table structure as:
    tbl_country
    CREATE TABLE "SCOTT"."TBL_COUNTRY"
       (    "CNTRY_CODE" NUMBER NOT NULL ENABLE,
        "NAME" VARCHAR2(80 BYTE),
         CONSTRAINT "TBL_COUNTRY_PK" PRIMARY KEY ("CNTRY_CODE")  
    tbl_state:
    CREATE TABLE "SCOTT"."TBL_STATE"
       (    "SATE_CODE" NUMBER NOT NULL ENABLE,
        "COUNTRY_CODE" NUMBER NOT NULL ENABLE,
        "STATE_NM" VARCHAR2(80 BYTE),
         CONSTRAINT "TBL_STATE_PK" PRIMARY KEY ("SATE_CODE")
         CONSTRAINT "FK_CNTRY_STATE" FOREIGN KEY ("COUNTRY_CODE")
    Table Date as:
    insert into tbl_COUNTRY values(0,'country ');
    insert into tbl_COUNTRY values(91,'HHH');
    insert into tbl_COUNTRY values(72,'III');
    insert into tbl_COUNTRY values(83,'JJJ');
    insert into tbl_state values(1,'state',0);
    insert into tbl_state values(2,'BH',91);
    insert into tbl_state values(3,'CI',72);
    insert into tbl_state values(4,'DI',72);
    insert into tbl_state values(5,'EH',91);
    insert into tbl_state values(6,'FI',72);
    insert into tbl_state values(7,'GJ',83);
    insert into tbl_state values(8,'HJ',83);
    insert into tbl_state values(9,'IH',91);
    Desired Output in oracle forms tree:
    |__Country
             |____HHH
                       |____BH
                       |____EH
                       |____IH
             |____III
                      |__CI
                      |__DI
                      |__FI
             |____JJJ
                       |__GJ
                       |__HJ
    I Have tried but got no output
    select
    1 ,level, esm.name,NULL,to_char(esm.CNTRY_CODE)
    from   (SELECT c.name,c.cntry_code from TBL_COUNTRY c union all select s.STATE_NM,s.COUNTRY_CODE from tbl_state s) esm
    connect by prior esm.CNTRY_CODE = esm.CNTRY_CODE
    start   with esm.code=0
    what is going wrong here.
    thank you
    regards
    aaditya

    If you have never worked with a Forms Tree control, I recommend you look at this tutorial: How To Create a Hierachical Tree form.
    Craig...

  • How to set the control-on hierarchical tree nodes

    Hi,
    I have created form in which at the left it has hierarchical tree structure(BOM) and towards the right it brings up the query results for selected node.
    Now, I have a button upon clicking which I navigate to the root node by issuing
    "Ftree.set_Tree_selection(htree, 1, Ftree.select_on);".
    But, it cannot automatically run the ' when-tree-node-selected' trigger '.
    any solution???
    Its really urgent.I have a customer demo on monday.
    Please help me asap.
    regards,
    Nagadeep.

    Hello Nagadeep,
    couldn't you just put the code from the trigger into a procedure
    and run that after the navigation to the item?
    Just a thought,
    Bernd
    The docs state that:
    No programmatic action will cause the When-Tree-Node-Selected trigger to fire. Only end-user action will generate an event.
    Probably due to performance reasons.
    Bernd
    Message was edited by:
    Bernd Prechtl

  • How to expand all the nodes in a tree while loading the tree initially

    Hi All
    Now i am able to display the tree strucute in webdynpro.
    but it is displaying the tree initially in collapsed mode until/unless we click on the node root it will be expanded.
    but my requirement is i wanted to display the tree in expanded mode by default at runtime initially.
    can you please provide any setting to be done or any sample code on the same then it would be great help to me.??
    Thanks
    Trisha

    Hi,
    isLeaf is an attribute you need to create under "CatalogEntries" node. And "isRoot" is not requried.
    Download the sample project "TutWD_TreeByNestingTableColumn". See the below link to dnld this project.
    https://www.sdn.sap.com/irj/sdn/index?rid=/webcontent/uuid/503f22f6-b978-2a10-bf97-ddc21267e752 [original link is broken]
    Do the changes in sample project as below:
    Invoke this method in the init method as below (as it is in the same project).
    addCatalogEntries(wdContext.nodeCatalogEntries(), "ROOT");
    Change the code in addCatalogEntries() method as below.
    Here we are calling the addCatalogEntries() method recursively for all the parent elements and we are changing the  setExpanded property to true.
    public void addCatalogEntries( com.sap.tut.wd.treetable.wdp.IPrivateTreeTableView.ICatalogEntriesNode node, java.lang.String parentId )
    //@@begin addCatalogEntries()
    IPrivateTreeTableView.ICatalogEntriesElement newCatalogEntriesElement;
    for (int i = 0; i < Catalog.getLength(); i++) {
    if (parentId.equals(Catalog.getParentId(i))) {
    // create new context node element
    newCatalogEntriesElement = node.createCatalogEntriesElement();
    node.addElement(newCatalogEntriesElement);
    // provide node elements with data
    newCatalogEntriesElement.setID(Catalog.getCATALOGID(i));
    newCatalogEntriesElement.setTITLE(Catalog.getTITLE(i));
    newCatalogEntriesElement.setDESCRIPTION(Catalog.getDESCRIPTION(i));
    newCatalogEntriesElement.setAMOUNT(Catalog.getAMOUNT(i));
    if ("ARTICLE".equals(Catalog.getCATALOGTYPE(i))) {
    // checkbox is visible by default
    newCatalogEntriesElement.setPUBLISHED(Catalog.getPUBLISHED(i));
    // third level is last level
    newCatalogEntriesElement.setIsLeaf(true);
    } else {
    // a CATEGORY does not use the checkbox column
    newCatalogEntriesElement.setUsageOfPublishedAttribute(WDVisibility.BLANK);
    newCatalogEntriesElement.setIsLeaf(false);
    newCatalogEntriesElement.setChildrenLoaded(true);
    newCatalogEntriesElement.setExpanded(true);
    addCatalogEntries(newCatalogEntriesElement.nodeChildCatalogEntries(),newCatalogEntriesElement.getID());

  • How to create input text of the node in AVL tree

    Hi experts,
    I create a simple AVL tree to display the sales order items, just two classes for one relationship. Like the left part on the screen in this program "DEMO_ABAP_OBJECTS_CONTROLS".
    I want to let the node of the second class be maintained serial no., somthing like input field behind the node or double click the node, then show up the input field on another space on the same screen.
    And there is a button on screen, I can do some check for the text of input field when pressing the button. If the input data is wrong , then show up the error message.
    I have searched BCALV* in SE38, but i don't see anything helpful.
    Plz give me some advice, thanks a lot!!
    Regards,
    Claire

    To Kunjal and Uwe,
    My AVL tree is declared like this:
    Data: tree TYPE REF TO cl_gui_simple_tree.
    The class is not  "cl_gui_alv_tree" , so I can not use the code.
    The code I create the node is the follwing:
    CALL METHOD tree->add_nodes
             EXPORTING table_structure_name = 'ABDEMONODE'
                       node_table = node_table.
    And I looked the program that Uwe wrote, the tree is declared in class cl_gui_alv_tree, too.
    I want to double click the node and appear a field that can be inputed text.
    Is there any other way to do this with the class cl_gui_simple_tree?
    Thanks for the advence help.
    Claire

  • Fetch the index of the node in a tree

    hi,
    i am using a recursive tree structure,
    i need to get the index value of a selected node in a tree structure,
    can any one help me?
    thanks in advance,
    Regards,
    Meyyappan

    Hello Ganesh,
    in that case, just call
      lr_node_tmp = context_element->get_node().
      lr_parent_element = lr_node_tmp->get_parent_element().
      lr_parent_node = lr_parent_element->get_node().
    Best regards,
    Thomas

Maybe you are looking for

  • Can I use the same email address for facetime on 2 different devices (ipod touch and a mini)

    can I use the same email address for facetime on 2 different devices (ipod touch and a mini)? I've set up my daughters ipod touch last year all fine. She's had a mini this yr but when setting up facetime and entering her email address, which is used

  • PL/SQL parser for 7.3 DB?

    We have an ORACLE 7.3 DB and are looking for a PL/SQL parser for XML... Some of the posts I've seen seem to suggest that a solution exists, but I'm not having any luck finding out for sure... Thanks, Jeff

  • MultiThreaded Server and Client connections query.

    I have written a MultiThreaded Server to accept incoming client requests. Multiple clients can connnect to this server and have a conversation. I invoke the 'MultiServer' from the command line and then invoke 3 clients from the command line.('Client'

  • Help with Tabbed panels please

    Hello, Can someone please tell me how I can change the color of the background of the tabs in tabbed panels.  They are a grey and I can go into each tab and set a new color and when that tab is chose, the new color shows, but when I click on the next

  • My Mdaughter got a ndew ipod and is missing some itunes she purchased.

    My daughter got a new ipod and can't find some of her recent purchases.  How can I find out what she has purchased and get them back?