Re: Dynamically adding nodes without a TreeModel
- From: "Raja" <rajak27@xxxxxxxxx>
- Date: 10 Nov 2005 11:37:47 -0800
You must either use DefaultTreeModel.insertNodeInto() event or fire the
fireTreeNodesInserted() event.
- Raja.
Srikanth wrote:
> Hi,
>
> I am adding nodes dynamically after the tree is visible. It's adding
> the first child node I create and it is showing it. When I add a second
> node, it doesn't show the that. And when I debug the code I found that
> the node was added to the tree but it is not visible. I tried by
> expanding and collapsing the tree manually, but it didn't work.
>
> I am not using any TreeModel as such. So, how do I make the change
> visible??? I am even calling the repaint() method of JTree, what could
> be the problem and is it better if I create my own TreeModel class and
> use it???
>
> Thank you,
> Srikanth...
.
- References:
- Dynamically adding nodes without a TreeModel
- From: Srikanth
- Dynamically adding nodes without a TreeModel
- Prev by Date: Re: Problem setting focus in a tabbed pane
- Next by Date: Re: flashing a JXTreeTable cell
- Previous by thread: Re: Dynamically adding nodes without a TreeModel
- Next by thread: Update-able Graph in Web Application
- Index(es):