How to Implement Dynamic Tree structure in jsp

Hi,
Does any body help me to solve out my requirement??
I want to display all my folder contents (parent & childs) in windows explorer format, the root folder path will come from database.
Thanks in advance

There are many ways to achieve this. The simplest would be to use some existing tag library that renders a tree structure and feed it with the required data.

Similar Messages

  • Dynamic Tree Creation using JSP, Struts framework

    I urgently require tips/information/code snippet for creating a Dynamic Tree structure.
    Tree is the hierarchical folder structure that we see in windows operating system.
    Dynamic tree in the sense that all nodes shall be populated from database & a radio button shall be present at each node that can be selected & submitted to form.
    Tree should be done using JSP (& if required Javascript).
    I am using Struts framework .
    [email protected]

    u need to know quite a few java technologies to make archieve your dream.
    JDBC, dynamic array and JSP.
    after reading tutorial regarding to these 3 materials, you should be able to get your job done.

  • Tree Structure in JSP

    Hi,
    I have an xml file , my requirement needs me to display the xml file as a tree structure in jsp. The user should be able to make changes to tree. he can drag and drop the nodes and save the changes.
    I parsed the xml file and created a method that returns an arrayList of the immediate children given a node.I'am not getting how to proceed from there on.
    Can anyone provide me with any useful tips or code. I can use javascript css java(not swing).Please reply ASAP as I have to complete it soon.
    Thanks,
    Sabi

    Hi why dont you try the link below,
    basically its for menu u can change it,
    http://demo.raibledesigns.com/struts-menu/
    in the above link see the following hyperlink
    Expandable DHTML List Example - Shows Expandable DHTML list

  • How to create a tree structure using forms.

    Hi,
    How do i create a tree structure using oracle forms,i have a table named Functions and a specific column 'Function Name' should be displayed in the tree nodes.Can anyone help me out on how to create a tree structure and populating the nodes??
    thanks in advance
    Regards
    Karthik

    The FTree package provides functions to populate the tree - look for the topic "Manipulating a hierarchical tree at runtime
    " in the online help this point to all the functions and triggers

  • How to create a tree structure using list items(tlist)

    HI every one,
    As we know how to create a tree structure using Hierarchy item type.
    We have a requirement to create The same tree like structure using List Item(Tlist)
    I would be so appreciated If you send with an example
    Thanks
    RangaReddy

    Hi all
    Any one help me please
    Actually our client requirement is creation of tree structure using list item,similar to what we used in oracle Application(FNDSCSGN) form.We did the tree structure using hierarchy tree using Htree and Ftree.It working excelently.For client requirement, we want to use list item.How PJC(Pluggable Java Components) is useful for using list item(Tlist).I can't understand how it is useful.
    Do you have any example please help me.
    Thanks
    RangaReddy

  • How to create a tree structure,like I want to create Bill/Payment Tree

    How to create a tree structure , like I want to create a Bill/Payment Tree containing a single node for all A/R related activities for a specific bill period, in reverse chronological order. Basically the tree should look like
    + Bill - Date: 03-17-2010 Complete
    +++++ CR Note - Date: 05-04-2010 Complete
    ++++++++++ Pay - Date: 05-04-2010 Frozen
    + Bill - Date: 03-17-2010 Complete
    +++++ Pay - Date: 05-04-2010 Frozen
    And finally this should be attached as tab on the control central

    The FTree package provides functions to populate the tree - look for the topic "Manipulating a hierarchical tree at runtime
    " in the online help this point to all the functions and triggers

  • How to delet OM Tree structure

    Hi,
    Could you please tell me how to delet OM tree structure which i created in simple maintenance method.
    Though i delete frm edit - delete from the bottom of the screen its still reflecting so any other permanent way delete the tree structure.
    Thanks
    Vibin

    Hi,
    Try deleting all relationships etc assigned to the object then delete the object completely.
    Salil

  • How compile an entire tree structure packages in JDev

    Hello there
    When i use jdev i have the src folder (source files) and the classes folder (compiled files) as Jdev makes them, but the compiled files are not updated correctly.
    For eg. i created a batch file that runs the application with this content
    echo on
    C:
    set path=C:\Program Files\Java\jdk1.6.0_11\bin;%path%
    set classpath=
    cd C:\jdevstudio10133\jdev\mywork\Supreme\ProjectServer\classes
    java project.main.Main
    And the application started is an older version of the application that i have now, if i put the first line System.out.println("Message") even if i make and rebuild the project, the message will not appear and i dont know how to get the compiled files.
    Also i tried to find out how to compile a tree structure of packages from command line but it seems very difficult. If anyone can give a reference.
    Thank you.

    User,
    you left out vital information. Read this post before posting.
    what happens if you delete the whole classes folder and rebuild the application? JDev will recreate the folder and you should see all changes then. If not you are not running the right classes.
    Timo

  • Creating a tree structure in jsp- URGENT

    Hi,
    I need to create a tree structure using jsp. Can anybody help me out.
    Thanks in advance.

    to do what? to store what? be more specific dude. As a first suggestion use XML.

  • How to get Tree structure in JSP page?

    Hi,
    I would like get data from the database and display the data in tree structure with the check boxes at each nodes on a jsp page with out using any third party tools. how can i do that? Do i require any new tags to fulfill this requirement?
    can any one help me out by sending any example code?
    thanks in advance.
    Regards,
    Reddy

    Once you have the data in a list or something, can't you just use <c:forEach> and then output standard nested <ul> and <li> tags to give the tree structure.
    <html>
         <style>
              li
                   list-style-type:none;
         </style>
         <body>
              <form>
                   <ul>
                        <li>
                             <input type="checkbox">Check 1</input>
                             <ul>
                                  <li>
                                       <input type="checkbox">Check 1A</input>
                                  </li>
                                  <li>
                                       <input type="checkbox">Check 1B</input>
                                  </li>
                             </ul>
                        </li>
                        <li>
                             <input type="checkbox">Check 2</input>
                             <ul>
                                  <li>
                                       <input type="checkbox">Check 2A</input>
                                  </li>
                             </ul>
                        </li>
                        <li>
                             <input type="checkbox">Check 3</input>
                        </li>
                   </ul>
              </form>
         </body>
    </html>

  • Dynamic menu in tree structure in JSP

    Hi,
    1) I need to display a dynamic menu in JSP. The menu depends on the values received from database. I need to show the items in the structure of tree (like parents, child relation). The tree can have multiple levels (the parent can have children & these children too can have children). This tree structure would be on left side of the screen.
    I would like to use some custom tags rather than javascript. Can somebody post the custom tags or some samples?
    2) Also, once the user selects different items from menu, different action classes should be called. And accordingly, the right side of the screen will show different data.
    So, there should be any way to set different action classes for the menu items. Please post any samples or helpful links.

    Hi,
    1) I need to display a dynamic menu in JSP. The menu depends on the values received from database. I need to show the items in the structure of tree (like parents, child relation). The tree can have multiple levels (the parent can have children & these children too can have children). This tree structure would be on left side of the screen.
    I would like to use some custom tags rather than javascript. Can somebody post the custom tags or some samples?
    2) Also, once the user selects different items from menu, different action classes should be called. And accordingly, the right side of the screen will show different data.
    So, there should be any way to set different action classes for the menu items. Please post any samples or helpful links.

  • How to retrive dynamic directory structure from data base and show it

    i want to display a directory structur on jsp my problem is that i want to read it from a database how i can read
    a tree structure i found a function to read directry structur but if i use this function i am not able to find who the parent is ? this is the function i found cna any one help me ?
    public void iterate(File someDirectory) {
    Vector allFiles = new Vector();
    File[] dirContents = someDirectory.listFiles();
    for (File f : dirContents) {
    allFiles.add(f);
    for (int i = 0; i < allFiles.size(); i++) {
    File file = (File) allFiles.get(i);
    if (file.isDirectory()) {
    dirContents = file.listFiles();
    for (File f : dirContents) {
    allFiles.add(f);
    // Process 'file' or do whatever
    }

    Thanks for reply i am not actualy deling with files i am creating a web application in which i am having organize functionality
    user creat folders and put there document in that like out look user can creat folder inside folder
    i am storing tham in a database table my problem is how to retrive them so i can show them as a tree structur
    i am using this code to show on jsp
    {color:#808000}<table>
    <tr>
    <td >
    <ul class="flipMenu">
    <li><span class="menu">Folder</span>
    <ul>
    <c:forEach var="folderList1" items="${folderList}" >
    {color}
    {color:#808000}<li ><a class="submenu25" id='<c:out value="${folderList1.id}"/>' href="folderAgreement.htm?folderid=<c:out value="${folderList1.id}"/>" onmouseup="a('<c:out value="${folderList1.id}"/>');" ><span ><c:out value="${folderList1.name}" /> T</span></a>
    <ul>
    <li> <a href="# onclick="window.open('createSubFolder.htm?folderid=<c:out value="${folderList1.id"/>&agreetitle=<c:out value="${agreements.title}"/>', 'invite_wnd', 'height=700, width=800, status=no, menubar=no, toolbar=nu, location=400'); return false;">Add Folder
    </li>
    <li> <a href="folderDetail.htm?folderid=<c:out value=${folderList1.id"/>&flag=folder"><span class="submenu2">Detail</span>
    </li>
    <li> <a id="<c:out value="${folderList1.id}"/>" href="folderDelete.htm?folderid=<c:out value="${folderList1.id}"/>&flag=folder" onclick="conformDelete('<c:out value="${folderList1.id}"/>')" ><span class="submenu2">Delete Folder</span></a>
    </li>
    </ul>
    </li>
    </c:forEach>
    {color}
    {color:#808000}</ul>
    </li>
    </ul>
    </td>
    </tr>
    </table>{color}

  • How to create dynamic tree based on BAPI

    Hi
    I am able to create dynamic tree based on flat file structure example given in SDN . But how to create the tree from BAPI directly.Also when I will be clicking on any leaf node of the tree some data related to the node will be passed to another view.
    Regards
    Ananda

    What i'm trying to do is create an organizational structure.
    Global>Region>Plant-->Corporation
    The output from the RFC is a structure containing every possible combination for orgazational hierarchy. Basically a flat table with record for every possible combinaton of Region-Plant-Corporation. This data needs to be bound to a tree structure so that we can call BW queries based on that level. For example: Give me aged inventory for the SAP corporation within the plant Berlin that is located in the Europe region.
    Now that you understand the business reason will the nodes that represent Region and Plant and corporation be non-singleton nodes or recursive? I was thinking a hierarchy of non-singleton nodes.
    I can bind these nodes to the Region - Plant - Corporation elements returned from in the flat table structure. I will probably get duplicates as a specific Region will be listed multiple times for every possible combination of the data beneath it. I'm not so concerned about that right now as I want to make sure I understand how in Web Dynpro to bind the data to the tree.
    Hopefully this makes some sense. Can you elaborate on how this may be constructed in context of the view?
    Would i create a model node for region (0..n), model node for plant (0..n), and a model node for Corporation (0..n)?
    Or does this sound totally incorrect?
    julian
    We have 3 regions over 50 plants and probably around 500 corporations.

  • How to create dynamic tree component

    I am using netbeans 5.5 and visual web pack to develop my jsf application.
    I want to add a tree component that will be tied to a table with following columns:
    id,parent_id,name
    Actually the table stores data in tree structure with parent_id storing the parent of the row.
    So a row with parent_id = 0 will be the root nodes of the tree.
    When ever any root node is selected i want to fetch its children from the database and populate then as children of that parent node.
    The tree can go to any depth so i want to make my tree component dynamic enough to handle this requirement.
    How can i accomplish this.
    I just want to add listerner for the plus sign of every node so that when the plus sign of that node is clicked i just want to get the id of the corresponding node.

    What i'm trying to do is create an organizational structure.
    Global>Region>Plant-->Corporation
    The output from the RFC is a structure containing every possible combination for orgazational hierarchy. Basically a flat table with record for every possible combinaton of Region-Plant-Corporation. This data needs to be bound to a tree structure so that we can call BW queries based on that level. For example: Give me aged inventory for the SAP corporation within the plant Berlin that is located in the Europe region.
    Now that you understand the business reason will the nodes that represent Region and Plant and corporation be non-singleton nodes or recursive? I was thinking a hierarchy of non-singleton nodes.
    I can bind these nodes to the Region - Plant - Corporation elements returned from in the flat table structure. I will probably get duplicates as a specific Region will be listed multiple times for every possible combination of the data beneath it. I'm not so concerned about that right now as I want to make sure I understand how in Web Dynpro to bind the data to the tree.
    Hopefully this makes some sense. Can you elaborate on how this may be constructed in context of the view?
    Would i create a model node for region (0..n), model node for plant (0..n), and a model node for Corporation (0..n)?
    Or does this sound totally incorrect?
    julian
    We have 3 regions over 50 plants and probably around 500 corporations.

  • How to store a Tree Structure in Memory

    hi all!
    I wanted to show a Org Chart on web page. Recursion is used for constructing.Based on B/S architecture,(get Org from DataBase)this is not a effective way!! How can I store a tree structure(Org object are stored as TreeNodes) in memory for recursion??? Thanks!

    My English is too poor! So I posted the interfaces blow.
    I used these interface to construct a org tree(which will displyed in browser ),but it's
    efficiency is low. (recursion)Because the org infor. are stored in database(thounds of
    orgs are stored).(I think this is the bottleneck)
    Now I want to store the tree structure in memeory! Then jsp page only needs to build the tree
    from memory!Needn't make a DbConnection every time. A timer will updated tree org(in memory)
    automatic
    So I want to use a N dimensions array to store the data (N is the number of orgs)
    but I don't konw how to make a compositor for sorting!
    after sorting .look at the matrix I poster blow(eg.)
    Matrix:(a,b,c,d are orgs 1 mean's is parents 0 means not, this is a Sparse Set huh? ^_^ )
    * a b c d
    a 0 0 0 0
    b 1 0 0 0
    c 1 0 0 0
    d 0 1 0 0
    Org tree:
    a
    b c
    d
    so O(n(n-1)/2)
    question:
    1)How to sort orgs?
    2)Any good suggestion is wanted!
    Thanks!
    interfaces
    public interface IOrg {             //entity class
    public String getName(); //get Org Name
    public String getId(); //get Org Id
    public String getLevel(); //get Org Level (as String)
    public String getParentId(); //get parent org Id
    public String getDescription(); //get the description
    public boolean isActive(); //is Org active
    Org Factory
    import java.util.*;
    * Description of the Interface
    *@author ymruan
    *@created 2002��1��4��
    public interface IOrgFactory {
    public IOrg getOrgById(String orgId);
    public IOrg getOrgByObjId(String objId);
    public Enumeration getManagers(String orgId);
    public Enumeration getManagers(IOrg org);
    public Enumeration getEmployees(String orgId);
    public Enumeration getEmployees(IOrg org);
    public Enumeration getOrgsByLevel(String level);
    public Enumeration getAllOrgs();
    public Enumeration getOrgsLikeName(String name);
    public IOrg getParentOrg(IOrg org);
    public IOrg getRootOrg(); //get Root Org
    public Enumeration getChildOrgs(IOrg org); //get Ogg's children
    public boolean hasSubOrgs(IOrg org); // is leaf
    public boolean hasActiveSubOrgs(IOrg org);
    public boolean isInOrg(String orgId, String empId);
    public boolean hasEmployees(IOrg org);

Maybe you are looking for

  • [SOLVED] Problem with GDM and Gnome3

    Okay, the Topic was more of a trick. Actually I'm havingt two seperate issues; I googled and such, but have not found anything that really answers my question. First Issue: I have my gdm.service enabled, so it starts on statup. I boot into runlevel 3

  • Where Can I Buy A Tin Case For My Zen Mic

    Where can i buy one of those tin cases for zen micro's? i've seen some around and researched on google but cant seem to find any reatailers. links would be great. Thanks in advance

  • Any easy way to apply equalization?

    Due to high-frequency hearing loss (hereditary, not iPod-induced, BTW) I am having trouble hearing higher-pitched instruments played back on the new Shuttle. I know that the Shuttle's software does not have equalizer capability at present. I would li

  • Creative Cloud installs but will not open on windows 7

    Creative Cloud installs but will not open on windows 7

  • LR4 library filter not turning off?

    I'll apologize in advance, 'cause I suspect this is already in the forum, but I can't find it.......... Converted to LR4 last week.  This morning, I started it, and went into the library.  The open catalog has 31000 images. The Library Filter is OFF.