This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes Show the selected file and folder in tree structure with checkbox and the checkbox should be only.. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Show the selected file and folder in tree structure with checkbox and the checkbox should be only.." Watch "Show the selected file and folder in tree structure with checkbox and the checkbox should be only.." New topic
Author

Show the selected file and folder in tree structure with checkbox and the checkbox should be only..

shweta raghuwanshi
Greenhorn

Joined: Apr 12, 2011
Posts: 5
Dear all,

By using JFileChoor I am able to select file and folders, Getting JList with File
Objects and I am showing it with checkbox. Now my requirement is like I want to show the
selected file and folder in tree structure with checkbox and the checkbox should be only
for root elements not for all child elements. Please help me as soon as possible, for me
its very urgent.

Example : For Example, I selected folders ABC and PQR which containt sub folders and few files
now on UI It should be display like :

Checkbox1 ABC--
--SubFolders
. --SubFolder
. --Files
--Files
Checkbox2 PQR--
--SubFolders
. --SubFolder
. --Files
--Files



Regards,
Shweta
shweta raghuwanshi
Greenhorn

Joined: Apr 12, 2011
Posts: 5
Dear All,

I Just Now Created a Image with the Expected Structure.
I hope it will be help you guys to understand the problem.

Regards,
Anand


[Download Expected Structure.bmp] Download

Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19649
    
  18

shweta raghuwanshi wrote:Please help me as soon as possible, for me
its very urgent.

Please EaseUp. There is no such thing as urgent around here.

Are you already able to create the tree without the check boxes? Are you able, after having searched for solutions, to create the tree with check boxes for each node?


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
shweta raghuwanshi
Greenhorn

Joined: Apr 12, 2011
Posts: 5
Yes I am able to create the Tree Structure with check box with each Nodes. But I am not able to create it as per Pic I have posted
shweta raghuwanshi
Greenhorn

Joined: Apr 12, 2011
Posts: 5
Hi,

I am Apologized for mentioning the Urgency. I am sorry for this unconscious behavior. I will try to improve myself for the same.

Regards,
Anand
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Show the selected file and folder in tree structure with checkbox and the checkbox should be only..
 
Similar Threads
Unjar Folder
JTree with CheckBox
JSF with Weblogic 8.1 sp3
Selecting the directory
Apply CheckBox in Each Node in a JTree which fetches system file(JCheckbox and Jtree)