0

TREE (using SimpleTreeModel) upto 2 levels .

asked 2009-11-09 04:57:38 +0800

cros gravatar image cros
153

How can I get a TREE (using SimpleTreeModel) upto 2 levels .
it should be of the following structure ----

  -Root
    -h1
        -h1.1
        -h1.2
    -h2
    -h3

Please suggests me ????

delete flag offensive retag edit

5 Replies

Sort by ยป oldest newest

answered 2009-11-09 07:38:28 +0800

YamilBracho gravatar image YamilBracho
1722 2

Check http://en.wikibooks.org/wiki/ZK/How-Tos/Concepts-and-Tricks#How_to_open_treeitem_at_start

link publish delete flag offensive edit

answered 2009-11-10 02:32:45 +0800

cros gravatar image cros
153

updated 2009-11-10 02:33:17 +0800

Thanx a Lot Sir !!!

My other poblem is when I add nodes dynamically at diff levels like 2,3,4...., I am able to save the 'nodeName' and 'idofParentNode'(it is the id of selected node's Parent) ...

When i fire a query say "select nodeName,idofParentNode from Client", i get the data.

But what is the way to store these names so that I build a tree with same structure(as that while adding).

I am still confused if they are 7 levels ...then will I need 7 arrayLists?????

Pls help me...

link publish delete flag offensive edit

answered 2009-11-10 07:27:51 +0800

YamilBracho gravatar image YamilBracho
1722 2

If you are using a model, update the model (add, update or remove nodes) and then synchronize the model with the component...

link publish delete flag offensive edit

answered 2009-11-10 23:38:35 +0800

cros gravatar image cros
153

Can u explain me by giving an example Sir ?
Thanx in advance

link publish delete flag offensive edit

answered 2009-11-11 12:20:00 +0800

YamilBracho gravatar image YamilBracho
1722 2

Check http://docs.zkoss.org/wiki/ZK_Tree_Model

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2009-11-09 04:57:38 +0800

Seen: 895 times

Last updated: Nov 11 '09

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More