PDA

View Full Version : get selected object from tree widget.



red
27th July 2010, 14:39
Hello all,

I am a Maya 2011 user and I am testing some functionality in QT. The reason why I mention Maya 2011 is because Maya only uses the .ui file and nothing else. So I am not able to use any of the other QT files (.cpp or .h)

I have the following problem.

1) I have a button with a dynamic string property (-command)
2) I have a Tree Widget with some items in it
3) I would like that when I press the button the button gives the following command
myCommand(items selected in list)

4) I do not know how to get the items that are selected in the Tree Widget and give them to the button.

I have attached an example file.
5004

Any suggestions or tips would be most welcome !
Thanks.
Red