Tree in Table

Hi. I trying do tree in table but results are hopeless ;(
When i try do this by outline (netbeans library) I get exception:
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
     at org.netbeans.swing.outline.DefaultOutlineCellRenderer.getExpansionHandleWidth(DefaultOutlineCellRenderer.java:166)
     at org.netbeans.swing.outline.DefaultOutlineCellRenderer$ExpansionHandleBorder.getBorderInsets(DefaultOutlineCellRenderer.java:411)
     at javax.swing.border.CompoundBorder.getBorderInsets(CompoundBorder.java:146)
     at javax.swing.border.AbstractBorder.getBorderInsets(AbstractBorder.java:74)
     at javax.swing.JComponent.setBorder(JComponent.java:1796)
     at org.netbeans.swing.outline.DefaultOutlineCellRenderer.setBorder(DefaultOutlineCellRenderer.java:129)
     at javax.swing.table.DefaultTableCellRenderer.getTableCellRendererComponent(DefaultTableCellRenderer.java:254)
     at org.netbeans.swing.outline.DefaultOutlineCellRenderer.getTableCellRendererComponent(DefaultOutlineCellRenderer.java:240)
     at org.netbeans.swing.etable.ETableColumn.estimatedWidth(ETableColumn.java:365)
     at org.netbeans.swing.etable.ETableColumn.updatePreferredWidth(ETableColumn.java:282)
     at org.netbeans.swing.etable.ETable.updatePreferredWidths(ETable.java:1769)
     at org.netbeans.swing.etable.ETable.setModel(ETable.java:868)
     at org.netbeans.swing.outline.Outline.setModel(Outline.java:634)
     at main.ExplainPlanPanel.<init>(ExplainPlanPanel.java:42)
     at main.ExecutionPanel.<init>(ExecutionPanel.java:32)
     at main.Main.<init>(Main.java:41)
     at main.Main$4.run(Main.java:419)
     at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:251)
     at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:705)
     at java.awt.EventQueue.access$000(EventQueue.java:101)
     at java.awt.EventQueue$3.run(EventQueue.java:666)
     at java.awt.EventQueue$3.run(EventQueue.java:664)
     at java.security.AccessController.doPrivileged(Native Method)
     at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
     at java.awt.EventQueue.dispatchEvent(EventQueue.java:675)
     at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:211)
     at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:128)
     at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:117)
     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:113)
     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:105)
     at java.awt.EventDispatchThread.run(EventDispatchThread.java:90)

You might get more/better response by asking Netbeans questions on a Netbeans forum.

Similar Messages

  • How to create a tree in table?

    How to create a tree in table?

    Hi,
    check these links,
    Tree Structure:
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/de59f7c2-0401-0010-f08d-8659cef543ce
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/49f2ea90-0201-0010-ce8e-de18b94aee2d#31
    /people/paolo.romano2/blog/2007/11/09/dynamic-tree-in-abap-webdynpro
    Regards,
    Muneesh Gitta.

  • What i use to develop complex tree and table in my web application?

    hi guys
    simply most of my work in my web application will be depend on:
    1-tree
    2-table
    i need this tree and table deal with database table (or even tables) must be able to do every thing like add node/row/column, delete, update, drag-n-drop, various object nodes/cells like check-box, list, images...etc
    i used JTree and JTable then stoped because i faced problems in dealing with applet/database, and i really didnt see this is perfect way to do that even i agree that JTree and JTable are excellent objects. i also start using ajax tree but i didnt see it robust to have all this complicated work with database.
    by the way i need also master-detail UI table, but its easy to get this if i have good and flexable table object.
    my rest pages developed by jsp, servlet, javascript, html...etc
    so any suggestion to how i build this tree and table? i also heared about JSF, is it serve me?
    thanks

    so if the only way to use JTree and JTable,There are other ways, but they're not Java and might be more complicated.
    are there
    any links you have discussing dealing database with
    applet by keep applet away from direct connection to
    my database?I'm not aware of links, but it's common sense. You don't want to expose the DB server to the internet, and instead contact a server for authentication that then forwards the request to the DB.

  • Trees in table

    Is it possible to implement tree in table. If so, plz let me know.
    Thanks,

    Hi,
    Try go through this [blog |https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/c060fcb4-2c62-2b10-d2b2-f32407a5cc6f] by Abhimanyu where he explains displaying a tree in both an ALV & table. Hope this helps resolve your problem.
    Regards,
    Uday

  • Create tree list table for my pages

    Please, How do i populate a tree list table for my application pages for navigation if i have report1 on page number 1 and form 1 on page number 2 and how do i choose my root.

    Hi,
    Try giving the time constraint as T and the custom table in the Time cnstr. Tab. field.
    Check Infotype 0006 for reference, which has the subtype selection.
    Regards,
    Balaji. D

  • How to create a form on a tree structured table

    Hi,
    I have a table that is designed to do a tree structure  like:
    Table Name: test
    Fields:
    ID
    ParentID
    Description
    I created a browser (IR) (page 1) that calls a form (page 2)
    The form has the editing fields and at the bottom layer I have a reports region where I display the children records using a query like:
    select * from test where ParentID = :P2_ID
    I need at the region level to add a button to call a form to edit the child record (which is the same table) and when done, to return to the form again but to the parent record.
    How can I do that successfully? Is there any example:?
    Thank you

    Maybe this can help:
    http://apex.oracle.com/pls/otn/f?p=31517:157
    using instead of trigger on a view.
    Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://www.opal-consulting.de/training
    http://apex.oracle.com/pls/otn/f?p=31517:1
    -------------------------------------------------------------------

  • Lead selection with a tree-based table.

    I've created a recursive context node to display contents of a KM folder.  The structure has been mapped to a table, which works just fine.  I can expand nodes of the tree and display the contents of sub-folders.  Great.  However, I need to know which backing KM object has been selected via the table.  Since this is a recursive structure, using
    wdContext.currentXXXX()
    does not work, since that's the top of the tree.  Parameter mapping will only give you the column and/or row of the item selected in the table, not the object itself.
    I'm missing something obvious here, but I can't figure out how to get the context element behind the selected row in a table which is displaying a recursive structure.
    I can do this with a Tree structure, since you can map the 'path' parameter to the actual context object.  However, the Table UI doesn't offset that information (a severe oversight, at least in my mind).
    Suggestions?

    Thanks Armin, that works great.
    Had I finished reading this page:
    http://help.sap.com/saphelp_nw70/helpdata/en/60/1f1f056f057d4d962375efd3c92ed0/frameset.htm
    I would have found the correct documentation.

  • Trees, temp tables and apex

    Hello,
    Has anyone had any luck building trees that go against temp tables? My tree works great with a regular table but runs flaky when I change the table to a temp table. Is this a limitation with APEX?
    Thanks in advance,
    Sam

    Temporary tables that belong to a database session are not reliably accessible across Application Express page requests. You should look at apex collections for temporary storage that will be persistent for the life of the apex session.
    Scott

  • Tree and Table UI element with same data source (context)

    Hello,
    I am trying to build an application which shows an tree and an table UI which shows additional information to the selected tree node. (like Windows Explorer)
    I am using an context like this:
    Class - - - - - - - - --  (Mapped  value Node)
    - SubClass - - - - -  (Recursion Node)
    - id - - - - - - - - -- - -(Value attribute)
    - name - - - - - - - - -(Value attribute)
    For the tree I am unsing this event handler  
         public void onActionClassNodeSelected(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent, de.aequitas.sap.wd.java.easyclass.wdp.IPrivateEasyClassView.IClassElement element )
    wdModifyView contains this:
    public static void wdDoModifyView(IPrivateEasyClassView wdThis, IPrivateEasyClassView.IContextNode wdContext, com.sap.tc.webdynpro.progmodel.api.IWDView view, boolean firstTime)
        //@@begin wdDoModifyView
         IWDTable pictureTable = (IWDTable) view.getElement("PictureTable");
        if(firstTime)
             IWDTreeNodeType node = (IWDTreeNodeType) view.getElement("TreeNodeType");
             node.mappingOfOnLoadChildren().addSourceMapping("path", "element");
             node.mappingOfOnAction().addSourceMapping("path", "element");
    I think I could use now
    pictureTable.bindDataSource()
    , but do not know where to get the needed parameter.
    Thank You
    Bernd

    >
    Bernd Herbold wrote:
    > Hello,
    >
    > I am trying to build an application which shows an tree and an table UI which shows additional information to the selected tree node. (like Windows Explorer)
    >
    > I am using an context like this:
    > Class - - - - - - - - --  (Mapped  value Node)
    >  - SubClass - - - - -  (Recursion Node)
    >  - id - - - - - - - - -- - -(Value attribute)
    >  - name - - - - - - - - -(Value attribute)
    >  .
    >  .
    >  
    > For the tree I am unsing this event handler  
    >
         public void onActionClassNodeSelected(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent, de.aequitas.sap.wd.java.easyclass.wdp.IPrivateEasyClassView.IClassElement element )
    >  
    > wdModifyView contains this:
    >
    >  
    public static void wdDoModifyView(IPrivateEasyClassView wdThis, IPrivateEasyClassView.IContextNode wdContext, com.sap.tc.webdynpro.progmodel.api.IWDView view, boolean firstTime)
    >   {
    >     //@@begin wdDoModifyView
    >      IWDTable pictureTable = (IWDTable) view.getElement("PictureTable");
    >     if(firstTime)
    >     {
    >          IWDTreeNodeType node = (IWDTreeNodeType) view.getElement("TreeNodeType");
    >          node.mappingOfOnLoadChildren().addSourceMapping("path", "element");
    >          node.mappingOfOnAction().addSourceMapping("path", "element");
    >     }
    >
    > I think I could use now
    pictureTable.bindDataSource()
    , but do not know where to get the needed parameter.
    >
    > Thank You
    > Bernd
    Hi,
    Following is the code to do this
    //Your existing code
    IWDTable pictureTable = (IWDTable) view.getElement("PictureTable");
    //use the following code for binding
    IWDNodeInfo nodeInfo = wdContext.nodeClass().getNodeInfo();// Assuming class Node is bound to table.
    pictureTable.bindDataSource(nodeInfo);
    Regards
    Ayyapparaj

  • How to generate ADF Faces Tree from table ?

    Hi,
    i want to create menu for my application using ADF Faces af:tree component.i have one table containing : menu_id and parent_id , which use for describing relationship between menu ( parent/child ).
    Fact : i've already know how to create adf faces af:tree component from master/detail relationship tables.
    The question : how to create adf faces af:tree component from recursive master/detail relationship in one table ?
    to clearer understand my question,this is my MENU_DATA table script :
    CREATE TABLE MENU_DATA
    MENU_ID VARCHAR2(5 BYTE),
    DESCRIPTION VARCHAR2(50 BYTE),
    OPENLINK VARCHAR2(200 BYTE),
    PARENT_ID VARCHAR2(5 BYTE)
    this is what i mean recursive master/detail relationship ...
    ALTER TABLE MENU_DATA ADD (
    CONSTRAINT FK_PARENT_MENU_ID
    FOREIGN KEY (PARENT_ID)
    REFERENCES MENU_DATA (MENU_ID));
    Thanks a lot for help gurus...
    Ricky HP

    I have the same question on my mind...
    Without creating n (same number of level depth) VO, how can I build a recursive ADF Faces Tree ???

  • JavaFX for database driven applications? No Tree or Table components?

    Hi there,
    Most of the apps I do are database driven and require liberal use of tables and tree components. I see these are missing from JavaFX.
    So the questions I have are:
    Will they be introduced later?
    How does one create custom components for JavaFX?
    Are there any 3rd party components that offer this yet?
    thanks

    You can find an example of the Table component creation and usage on page:
    [http://jfx.wikia.com/wiki/SwingComponents|http://jfx.wikia.com/wiki/SwingComponents]

  • Tree Node Table question

    Hi,
    When a tree is built doesn't the ps_tree_node_tbl table get updated with all the nodes from the tree? Are there any processes that we need to run to get it in sync?
    Please advise.
    thank you

    Which tree are you writing a query for? Is the data in pstreenode?
    See also http://www.compshack.com/sql/traversing-dept-security-tree#comment-575
    Kind regards, Bart

  • UI Components for folder tabs, trees and tables

    I hear quite a lot lately about how JSF is the Web equivalent of Swing, but I cannot find any references of support for some of the advanced Swing components, such as JTabbedPane, JTree and JTable. Are there such components in JSF, either from Sun, or from third parties?

    Good question. I have a thick swing client that began
    life as an applet and ended as as
    Java-Web-Start-launched application. It makes HEAVY
    use of JTable.
    I'm guessing JSF won't help us.Don't jump to conclusion.
    First check out this resources:
    http://www.cs.sjsu.edu/faculty/horstman/corejsf/geary-horstmann-corejsf-chapter9.pdf
    http://www.manning.com/mann (buy book or take a look on source code)
    http://thejspbook.com/aboutjsfbook.jsp;jsessionid=a974mvl_TiKf
    (buy book or take a look on source code)
    https://bpcatalog.dev.java.net/nonav/solutions.html
    http://www.ourfaces.net:8080/ourfaces/
    http://myfaces.org/
    Let me know if you need more functionality.
    I'm developing couple of related components so let me know if you need some extra functionality.
    Let's start compete with Swing :-)
    Vladimir

  • Issue with creation of ADF Table from ADF Tree selection

    Hi,
    Following is the usecase.
    I've created ParentVO & ChildVO from a single table with view criteria to filter the nodes.And then created two View links ParentToChild & ChildToChild.
    Added VOs & corresponding ViewLinks to ApplicationModule. It's got created hierarchy as Parent1->Child1->Chiled2 in Data model section of AM.So Iam done with tree creation process in Model.
    As VC can't be applied for sub levels. In order to set the VCs for sublevels, followed the below approach.
    Created a bind variable for tree. I've set the VC for both parent & child VOs in managed bean before setting the tree variable in setTree method. So now Iam able to display the required tree in UI with applying VCs.
    Now , I can select the required nodes from tree and then click on command button to display the selection list as a table.
    In order to achieve this, I tried below two options.
    1) Created separate Child VO instance (Child3) from Child VO and applied same view which applied initially. and the dragged the Child3 from Datacontrol to UI(jsff) as a table. When I run the application,it's displaying all the records from the DB table without applying VCs.
    2) Dragged the Child2 as a table on UI. When I run the application, it's displaying first record from the table without applying VC.
    But no luck in getting the required functionality.
    I've Following queries.
    a) If we update any transient attribute value for an VO instance, will it effect at VO level or only for that particular instance?
    Why because, I've created new instance of same VO. But the changes are not effecting for transient attributes in the new instance of VO.
    b) Can some one suggest on my usecase to display the selected nodes from a tree in table format?
    I tried my level best to explain the usecase. But let me know,if you have any queries on my usecase.
    Thanks in advance,
    Samba.

    This is my code:
    <af:column id="c1" headerText="Sponsor Status">
    <af:selectOneChoice label="Label 2" id="soc1" value="#{row1.sponsorStatusDesc}"
    validator="#{backingBeanScope.EditSponsorDetails.OnSponsorStatusChange}"
    valuePassThru="true">
    <f:selectItems value="#{pageFlowScope.confLists.spStatus}"
    id="si1"/>
    </af:selectOneChoice>
    </af:column>
    and this i what HTML code says..
    <select id="confSponsor:r2:0:tbIEEEsp:0:soc1::content" class="x2h" name="confSponsor:r2:0:tbIEEEsp:0:soc1">
    <option _adftmpopt="t" value="" title=""></option>
    <option value="4" title="Approved">Approved</option>
    <option value="3" title="Declined">Declined</option>
    <option value="6" title="New">New</option>
    <option value="2" title="Not Valid">Not Valid</option>
    <option value="5" title="On Hold">On Hold</option>
    <option value="1" title="Pending Approval">Pending Approval</option>
    <option value="7" title="Unidentified">Unidentified</option>
    </select>
    Stll i cannot see any value populated in SelectOneChoice

  • Need to Store Infinite Tree in a single table

    Hi,
    I need to create infinite tree and also need to store it into a single table. I will perform operations like node deletion,movement etc.. according to the operation my tree should get updated.Can anyone please give me any suggestion??
    Thanks in Advance,
    Sumeet Gupta

    Hi,
    Not much to go on, but this table can hold an infinite tree. Work from that.
    SQL> create table tree (node number(15) not null, parent_node number(15))
    Table created.
    SQL> alter table tree add constraint tree_pk primary key (node)
    Table altered.
    SQL> alter table tree add constraint tree_tree_fk foreign key (parent_node) references tree (node)
    Table alteredEdit:
    If you are not already familar with hierarchial queries, I suggest you look here:
    [Hierarchial query|http://download.oracle.com/docs/cd/B28359_01/server.111/b28286/statements_10002.htm#sthref9434]
    Regards
    Peter
    Edited by: Peter on Mar 3, 2009 7:35 AM

Maybe you are looking for