How to make a JTree have multiple layers.
I was able to get children but how do I get grandchildren?
I was able to do it with arrays, but it has the unacceptable side effect of having the array toString as the name, which isn't what I want.
I've tried the JTree(TreeNode) constructor but when I tried something like this:
DynamicUtilTreeNode dutn = new DynamicUtilTreeNode("Bubba", names);
Object values = new Object;
values = dutn;
values = "Abanca";
values = "Davama";
DynamicUtilTreeNode dutn2 = new DynamicUtilTreeNode("Rilli", values);
jt = new JTree(dutn2);
And it's not showing the third level.
Bubba's children aren't showing up.
Re: How to make a JTree have multiple layers.