• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Develop UI displaying Tree Using XML

 
Vikas Kulkarni
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Techies,
I am in the process of developing a UI that should show a tree (not like folder structure).
The tree should start from root node and that may contain n-children and similarly n-levels.
Currently I have a XML file that has the information about the Parent Children relationships.

I wanted to know how to parse this XML and put in the form of UI, the bottom line is, "Developing UI by using XMLfile in Java Code".

I hope I am clear.

Waiting for the reply(ies).
Thanks
- Vikas DK
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13058
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This tutorial on using the DOM (Document Object Model) should get you started.
Bill
 
Vikas Kulkarni
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Williams,
Thanks a million, I am going through the material that u sent, seems helpful.

I will ask doubts if i get any in midway

Thanks for your help

- Vikas DK
 
Vikas Kulkarni
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Williams,
The tutorial basically deals with the implementation of the JTree.
I DONT want to use JTree since it displays the tree in the form of directory structure .
I want my tree to be like B+ tree kind of.

I hope I am clear.

Thanks
- Vikas DK
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13058
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The way I see it there are three parts to your problem.

1. Designing a data structure that can hold the data in a form that makes it convenient to construct the display.

2. Extracting data from the DOM and placing it in that data structure.

3. Creating the display from the data structure.

XML is really only involved in part 2 and is not necessary in parts 1 and 3. If this was my problem I would start with sketches of what the display should look like from various types of data and tackle job 1 first. In other words, don't try to jump directly from XML to the display, work out part 1 first.
 
Ketan Khairnar
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hmm
I have a rough solution..
I had done that in the past...but my UI was in JSPs..I had used dTree.js which is available freely on net and you have to modify contents in that JS runtime..which I htink is possible in your case(Java)
 
Vikas Kulkarni
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ketan,
Do we need ABAP to run this script? I mean basically how to use this script and check the output. I tried finding the info over search engines but in vain.

Can u please help me ?

Thanks
- Vikas DK
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic