Notifications
Clear all

[Closed] DotNet TreeView Multiple select?

I’m not very familiar with dotNet or the dotNet treeview control, but I did just run the one provided in the Maxscript help files.

Looks like in that control, you can’t select multiple nodes at once. Is there any way to modify it so that you can?

Thanks!

9 Replies
1 Reply
(@rustyknight)
Joined: 2 years ago

Posts: 0

Short answer, no…for some reason, Microsoft didn’t seem to think this feature was important…

Long anser…yes, but you will need to code it yourself or download one the implementations on the net…this would be okay if you intend not to share the script, but a real bummer if you do…

Shane

edt: https://sourceforge.net/projects/mstreeview

When you say I’d need to code it myself, are you saying that it can be done in Maxscript, or that it needs to be implemented externally somehow?

2 Replies
(@rustyknight)
Joined: 2 years ago

Posts: 0

Sorry, I should have explained myself a little better…

No it can’t be done in max – from what I’ve read. The dotnet control simply does not provide the required support…for some reason…

You would either need to download one of the other extentions of the control that do provide the support or write your own, in C++/C#

How well this would fit back into max, I’m not fully aware, but since I believe some one wrote a listview sorter in C# and presented it here I would imagine it would be possible.

The immediate issue I see with it though, is you will need to distribute the “extra” control along with your script, which is just another hassel for the end-user…

Shane

(@pjanssen)
Joined: 2 years ago

Posts: 0

Works without any problems. The one you linked is a very nice one. The only thing you might want to do is download the source and fix the editlabel focus bug.
For an example of it’s use, take a look at my outliner tool.

The immediate issue I see with it though, is you will need to distribute the “extra” control along with your script, which is just another hassel for the end-user…

Shouldn’t be much of a hassle really. You can just put it in the same directory as the script, and have the script load it.

Great!! Thanks everyone for your replies!

 PEN

You can also mock this up in MXs by tracking what has been selected and color the elements to makeit look like they are selected. Just store all the elements that you clicked on it an array and work on that.

1 Reply
(@pjanssen)
Joined: 2 years ago

Posts: 0

What I’m wondering about is, how would you avoid the removing of the bg coloring when a node is deselected? Because the treeview resets a node bg color after the ‘afterselect’ event is fired.

 PEN

re-color all the nodes that you have collected then.

That can be very slow when you’ve got a large selection.