Tree Control

Started by Jim Short, June 29, 2008, 12:11:10 PM

Previous topic - Next topic

Jim Short

Has anyone tried to duplicate the behavior of the Inventor Tree Control wit OpenDCL?

Thanks,
Jim
Jim Short

BazzaCAD

I don't know, what's it look like?
a.k.a.
Barry Ralphs
barryDOTralphsATgmailDOTcom

Jim Short

Attachment shows a tree with an end of part marker. One can drag it up and down the list. Everything it below is not processed and grayed out. I have seen very little info on programming for the tree control. I was wondering how the end of file marker is handled. Do you think its just another parent?

Thanks,
Jim
Jim Short

BazzaCAD

I don't think you can drag-n-drop within the same tree control. (maybe that should be added as a feature request).
But you could add some up & down arrow buttons to move the "End of Part" node & change the image for all the other nodes below it.
a.k.a.
Barry Ralphs
barryDOTralphsATgmailDOTcom

Jim Short

Is that a limitation of the MFC Tree Control or OpenDCL's implementation?
Jim Short

owenwengerd

Quote from: BazzaCAD on July 03, 2008, 10:21:16 AM
I don't think you can drag-n-drop within the same tree control.

You should be able to, if it is enabled.
Owen Wengerd (Outside The Box) / ManuSoft

Fred Tomke

Hello, I want to add something, too  ;)

1. Owen is right: drag'n drop works within one and the same tree control, I use it very often in cases of data management (with database behind) to manage structures. It is not really difficult - but its a lot of code (which item is allowed to be moved, which item can be child of another item, parents cannot be child of its own child and so on). But maybe Barry meant something different when he said "I don't think you can drag-n-drop within the same tree control."

2. The only pity thing is that OpenDCL does not support overlaying images (see icons of lnk-files (links) at your desktop with the small arrow at lower left). So thats why you have to manage it by yourself: just change the images at runtime. I always say: Everything I have to manage by myself can have the positive effect that I always have the control over it: I can decide when I want to do something and when not.

Maybe we should think about an advanced example with tree control using drag & drop...

Fred
Fred Tomke
Dipl.-Ing. (FH) Landespflege

[ landscaper - landscape developer - digital landscape and urban design]

BazzaCAD

Sorry, I must have misspoke. oops :)
An advanced example would be nice.
a.k.a.
Barry Ralphs
barryDOTralphsATgmailDOTcom

Fred Tomke

I try to attach a video at first to see if it is this what Jim meant.

In the video I move different objects into other folders or below other objects. I have to make sure programmatically that the user won't move a filter (at the bottom of the tree) below a standard folder (at the top of the tree). This is not really a good example because I reread the complete hierarchy anew everytime, at last was too lazy.  :P

Such an advanced example would take a bit of time. I dreamt of an example combining AdoDb (using access database), Tree, Grid, ListView and a SQL Builder in a nice dialog. But at first I have to make real (my bad english: become true?) some other given promises before getting into this project.

Fred
Fred Tomke
Dipl.-Ing. (FH) Landespflege

[ landscaper - landscape developer - digital landscape and urban design]

Jim Short

I think this is what I meant. Video runs a little fast.
thanks,
Jim
Jim Short